Ticket UUID: | 3556779 | |||
Title: | No calendar in August | |||
Type: | Bug | Version: | None | |
Submitter: | klu | Created on: | 2012-08-12 21:30:54 | |
Subsystem: | tklib :: widget | Assigned To: | andreas_kupries | |
Priority: | 5 Medium | Severity: | ||
Status: | Closed | Last Modified: | 2012-08-14 23:45:00 | |
Resolution: | Out of Date | Closed By: | andreas_kupries | |
Closed on: | 2012-08-14 16:45:00 | |||
Description: |
I use widget_calendar with this command: widget::calendar .z5fd.app.frdia.date -dateformat "%Y-%m-%d" -language de -textvariable zAr_uiDia(exposureDate) -command z5ui_selectedDate In July all works fine .. today, Index 08 = August ??? Executing the script i get: bad index "08": must be integer?[+-]integer? or end?[+-]integer? (looks like invalid octal number) bad index "08": must be integer?[+-]integer? or end?[+-]integer? (looks like invalid octal number) while executing "lindex $LANGS(mn,$lang) $month" (procedure "::widget::calendar::Snit_methodformatMY" line 9) invoked from within "$self formatMY $data(month) $data(year)" (procedure "::widget::calendar::Snit_methodRefresh" line 42) invoked from within ".z5fd.app.frstor.date Refresh" ("uplevel" body line 1) invoked from within "uplevel 1 [linsert $args 0 $self]" invoked from within "::snit::RT.CallInstance ::widget::calendar::Snit_inst1 Refresh" ("after" script) bad index "08": must be integer?[+-]integer? or end?[+-]integer? (looks like invalid octal number) bad index "08": must be integer?[+-]integer? or end?[+-]integer? (looks like invalid octal number) while executing "lindex $LANGS(mn,$lang) $month" (procedure "::widget::calendar::Snit_methodformatMY" line 9) invoked from within "$self formatMY $data(month) $data(year)" (procedure "::widget::calendar::Snit_methodRefresh" line 42) invoked from within ".z5fd.app.frstor.date Refresh" ("uplevel" body line 1) invoked from within "uplevel 1 [linsert $args 0 $self]" invoked from within "::snit::RT.CallInstance ::widget::calendar::Snit_inst1 Refresh" ("after" script) I got this error both - on a linux-System and on win7, active-tcl 8.5.11, tklib 0.5 well, i hope, you can help regards Bernd | |||
User Comments: |
andreas_kupries added on 2012-08-14 23:45:00:
allow_comments - 1 andreas_kupries added on 2012-08-14 23:44:41: Ok, so definitely a version from before the fix. Glad to hear the CVS is working. Yes, we should make a new release of tklib. (Side note: I usually use ActiveTcl, and then update individual packages from the teapot, so I usually have near-current packages around. Disclosure: I am a maintainer of ActiveTcl for ActiveState). klu added on 2012-08-14 20:23:45: well, http://www.tcl.tk/ links tklib, version 0.5 to http://sourceforge.net/projects/tcllib/files/tklib/0.5/ . Download this version tklib 0.5 (2009-01-27) installs widget_calendar Version 0.9 . I took your suggestion and installed all widget -files from cvs -Repository, currently the scripts working fine and no error occurred - Thank you very much! Maybe, there is time -in the future- to make a bugfix-Release of tklib - Version 0.51 ;) ? kind regards Bernd andreas_kupries added on 2012-08-14 01:45:49: Hm. Which version of the calendar widget is this ? I tried to reproduce using widget::calendar 1.0 in the CVS head, without my patch, and I did not have the problem. It might be that this already fixed in the CVS head, just not yet in any tklib release ... Reviewing the ChangeLog the answer is yes, this got fixed in the CVS (about 7 months after the 0.5 release). 2009-08-17 Jeff Hobbs <[email protected]> * calendar.tcl: correct leading 0-month issues. Make 8.4-friendly by not needing clock scan -format. * pkgIndex.tcl: bump calendar to v0.91 andreas_kupries added on 2012-08-14 01:31:51: Patch with fix attached. Review showed no other place where this is an issue (for month information). Unclear yet if days (i.e. 08, 09 in each month) have a similar issue. andreas_kupries added on 2012-08-14 01:30:50: File Added - 451150: cal.patch andreas_kupries added on 2012-08-14 01:30:22: Ah, the well-known problem of octal processing in Tcl. 0* is trated as octal, and 08 (09) are out of the proper range for that treatment. |
Attachments:
- cal.patch [download] added by andreas_kupries on 2012-08-14 01:30:50. [details]