Skip Menu |
 

This queue is for tickets about the Tcl-pTk CPAN distribution.

Report information
The Basics
Id: 128813
Status: resolved
Priority: 0/
Queue: Tcl-pTk

People
Owner: CAC [...] cpan.org
Requestors: CAC [...] cpan.org
Cc: ANDK [...] cpan.org
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.96
Fixed in: 1.00



CC: ANDK [...] cpan.org
Subject: t/tileLabelFont.t - bad option "ttk": must be cget or configure
Hi Andreas,

I noticed this failure reported by some of your testers, for example: http://www.cpantesters.org/cpan/report/1d8072a2-3e4c-11e9-8323-8a76cead5ccb



I have not yet reproduced these failures, so I would like to gather more information if possible. Which Tcl/Tk patchlevel are these tests run under? If using the Tcl/Tk packages provided by Debian, then I would guess they are run on Tcl/Tk 8.6.9 (the current version for Debian 10 buster/testing). I would also like to know exactly which line fails; could you please manually run t/tileLabelFont.t using `perl -d` and provide the stack trace?

Thanks




bad option "ttk": must be cget or configure at /tmp/loop_over_bdir-17336-PdzZn8/Tcl-pTk-0.96-0/blib/lib/Tcl/pTk/Widget.pm line 336.
t/tileLabelFont.t ............. 
Dubious, test returned 25 (wstat 6400, 0x1900)
Failed 3/3 subtests 
 
 
Test Summary Report
-------------------
t/tileLabelFont.t           (Wstat: 6400 Tests: 0 Failed: 0)
  Non-zero exit status: 25
  Parse errors: Bad plan.  You planned 3 tests but ran 0.
CC: ANDK [...] cpan.org
Subject: Re: [rt.cpan.org #128813] t/tileLabelFont.t - bad option "ttk": must be cget or configure
Date: Tue, 12 Mar 2019 22:03:49 +0100
To: "Christopher Alexander Chavez via RT" <bug-Tcl-pTk [...] rt.cpan.org>
From: Andreas Koenig <andreas.koenig.7os6VVqR [...] franz.ak.mind.de>
Download (untitled) / with headers
text/plain 2.2k
Show quoted text
>>>>> On Sun, 10 Mar 2019 17:53:51 -0400, "Christopher Alexander Chavez via RT" <bug-Tcl-pTk@rt.cpan.org> said:
Show quoted text
> Which Tcl/Tk patchlevel are these tests run under?
Both 8.4 and 8.6 are installed, I do not know how to determine which one was chosen by Tcl-pTk. Show quoted text
> If using the Tcl/Tk packages provided by Debian, then I would guess > they are run on Tcl/Tk 8.6.9 (the current version for Debian 10 > buster/testing).
The system is a Debian sid, latests updates around October 2018. I just ran the test on my more recent Debian sid and all tests passed there. Show quoted text
> I would also like to know exactly which line fails; > could you please manually run t/tileLabelFont.t using `perl -d` and > provide the stack trace?
% make testdb TEST_FILE=t/tileLabelFont.t PERL_DL_NONLAZY=1 "/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.24.4/af11/bin/perl" -d "-Iblib/lib" "-Iblib/arch" t/tileLabelFont.t Loading DB routines from perl5db.pl version 1.49_05 Editor support available. Enter h or 'h h' for help, or 'man perldebug' for more help. main::(t/tileLabelFont.t:11): plan tests => 3; DB<1> n 1..3 # Running under perl version 5.024004 for linux # Current time local: Tue Mar 12 20:25:42 2019 # Current time GMT: Tue Mar 12 20:25:42 2019 # Using Test.pm version 1.28_01 main::(t/tileLabelFont.t:13): my $TOP = MainWindow->new(); DB<1> main::(t/tileLabelFont.t:15): my $label = $TOP->ttkLabel(-text => "Hey Dude")->pack(); DB<1> bad option "ttk": must be cget or configure at blib/lib/Tcl/pTk/Widget.pm line 336. at blib/lib/Tcl/pTk/Widget.pm line 336. Tcl::pTk::Widget::call(Tcl::pTk::MainWindow=HASH(0x55b9a7c1de68), ".", "ttk", "label", "-text", "Hey Dude") called at blib/lib/Tcl/pTk/Widget.pm line 2815 Tcl::pTk::Widget::__ANON__[blib/lib/Tcl/pTk/Widget.pm:2816](Tcl::pTk::MainWindow=HASH(0x55b9a7c1de68), "-text", "Hey Dude") called at blib/lib/Tcl/pTk/Widget.pm line 2885 Tcl::pTk::Widget::AUTOLOAD called at blib/lib/Tcl/pTk/MainWindow.pm line 14 Tcl::pTk::MainWindow::AUTOLOAD(Tcl::pTk::MainWindow=HASH(0x55b9a7c1de68), "-text", "Hey Dude") called at t/tileLabelFont.t line 15 Debugged program terminated. Use q to quit or R to restart, Show quoted text
> Thanks
You're welcome! Let me know if you have further questions. -- andreas
RT-Send-CC: ANDK [...] cpan.org
On Tue Mar 12 16:04:02 2019, andreas.koenig.7os6VVqR@franz.ak.mind.de wrote:
Show quoted text
> >>>>> On Sun, 10 Mar 2019 17:53:51 -0400, "Christopher Alexander Chavez
> >>>>> via RT" <bug-Tcl-pTk@rt.cpan.org> said:
>
> > Which Tcl/Tk patchlevel are these tests run under?
>
> Both 8.4 and 8.6 are installed, I do not know how to determine which
> one
> was chosen by Tcl-pTk.
>

Could you try the following:

perl -e "use Tcl; print Tcl->new->Eval('info patchlevel')"
CC: ANDK [...] cpan.org
Subject: Re: [rt.cpan.org #128813] t/tileLabelFont.t - bad option "ttk": must be cget or configure
Date: Wed, 13 Mar 2019 04:32:33 +0100
To: "Christopher Alexander Chavez via RT" <bug-Tcl-pTk [...] rt.cpan.org>
From: Andreas Koenig <andreas.koenig.7os6VVqR [...] franz.ak.mind.de>
Download (untitled) / with headers
text/plain 711b
Show quoted text
>>>>> On Tue, 12 Mar 2019 17:11:05 -0400, "Christopher Alexander Chavez via RT" <bug-Tcl-pTk@rt.cpan.org> said:
Show quoted text
> -e "use Tcl; print Tcl->new->Eval('info patchlevel')"
Thanks, that helps a lot: % /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.24.4/af11/bin/perl -le "use Tcl; print Tcl->new->Eval('info patchlevel')" 8.4.20 I must retract what I said in my previous message, I was testing in the wrong window. The other Debian sid system actuall behaves the same, it has also both 8.4 and 8.6 installed and 8.4.20 was picked: % /home/sand/src/perl/repoperls/installed-perls/host/k93x64sid/v5.28.1/1170/bin/perl -le "use Tcl; print Tcl->new->Eval('info patchlevel')" 8.4.20 -- andreas
RT-Send-CC: ANDK [...] cpan.org
Thanks for following up and all the info so far.

The error makes sense now. Tcl::pTk to my knowledge only supports Tile widgets (like ttkLabel) under Tcl/Tk 8.5 or later; other tests that use Tile widgets check the version and skip if not using 8.5 later, so the easy fix is to add a version check to this test.


Some other notes:

It would be nice if the error shown here were more helpful, something like "Support for Tile widgets on Tk 8.4 not implemented".

I wonder why the previous authors of Tcl::pTk didn't add support for Tile on Tk 8.4, since Tile was originally an extension for Tk 8.4. I'm not sure supporting it now is worthwhile, though. At the moment I don't plan to remove Tcl/Tk 8.4 support, but it's not something I've personally used. Many OS package managers have dropped Tcl/Tk 8.4 (or even 8.5).

RT-Send-CC: ANDK [...] cpan.org
On Wed Mar 13 01:57:15 2019, CAC wrote:
Show quoted text
> I wonder why the previous authors of Tcl::pTk didn't add support for Tile on Tk
> 8.4, since Tile was originally an extension for Tk 8.4. I'm not sure supporting
> it now is worthwhile, though. At the moment I don't plan to remove Tcl/Tk 8.4
> support, but it's not something I've personally used. Many OS package
> managers have dropped Tcl/Tk 8.4 (or even 8.5).

The developers of Tcl/Tk have indicated they do not support 8.4, and encourage anyone using it to upgrade.

I have posted to the mailing list proposing to drop Tcl/Tk 8.4: https://www.mail-archive.com/tcltk@perl.org/msg00785.html
RT-Send-CC: ANDK [...] cpan.org
On Wed Mar 13 01:57:15 2019, CAC wrote:
Show quoted text
> The error makes sense now. Tcl::pTk to my knowledge only supports Tile widgets
> (like ttkLabel) under Tcl/Tk 8.5 or later; other tests that use Tile widgets
> check the version and skip if not using 8.5 later, so the easy fix is to add a
> version check to this test.

I have committed such a fix for this, and it will appear in the next release.

https://github.com/chrstphrchvz/perl-tcl-ptk/commit/333df8bb49811660c8c4f5afbe9d72d789e606f2


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.