| Ticket UUID: | 51aa53616067cb63900b17ca1d71f07b094ffa1a | ||
| Title: | clock timezone tests fail when ran against system tzdata | ||
| Type: | Bug | Created on: | 2026-02-27 17:34:56 |
| Submitter: | rossburton | Assigned to: | nobody |
| Subsystem: | 34. tcltest Package | Severity: | Minor |
| Priority: | 5 Medium | Last modified: | 2026-03-07 11:58:26 |
| Status: | Closed | Closed by: | sebres |
| Resolution: | Fixed | Closed on: | 2026-03-07 11:58:26 |
| Version: | |||
| Description: | ||||
|
I'm in a cross-compiled environment so running the tcl test suite outside of the build tree on the target to verify that tcl is working and integrated correctly. I build tcltest and install that and the tests/ directory. Most tests work:
However, if I run the clock tests with a tcl that didn't install the tzdata package in the library as we have /usr/share/zoneinfo:
Note that the in-tree tests work as they set TCL_LIBRARY to point at the source tree, which includes tzdata. It's entirely possible that I'm doing something wrong/dumb, but it's also possible that the tzdata loading has broke, or the copy of tzdata in tcl doesn't match the "real" tzdata 2025c that I have installed. | ||||
| User Comments: | ||||
sebres added on 2026-03-02 13:14:16:
Short analyze shows that there are basically 2 issues: 1. the format of TZ without Tcl's tzdata uses +02 instead of +0200 for %Z token, so the value of v contains:
2. the free scan consider +02 in opposite to formatted scan as +2 minutes "zone", so for the free scan it is the same than +0002 and not +0200:
jan.nijtmans added on 2026-03-04 08:01:13:
@sebres, is this ticket fixed now as well with your change? sebres added on 2026-03-04 11:18:17:
No, it is not (probably even much worse, because of different TZs now since last change)... I'm still in... got no time yet to fix it (or rather found another issue in the meantime, which is fixed now). sebres added on 2026-03-04 17:36:14:
OK, I can confirm that a lot of tests failed if there is no "tzdata in the library (as we have /usr/share/zoneinfo)". Besides mentioned issues, there are several others... But I see failures on all tests covering daylight switch, timestamps around DST-hole, etc. And such failures are generally not OK in my opinion. For instance:
So either some aliasing is wrong in zones of "/usr/share/zoneinfo" (e. g. CET is really an alias to +0100, without DST-switches etc). Thus the issue grows and grows. sebres added on 2026-03-04 22:41:23:
[6ea85b82c5b408c6] fixes that for v.9.0+, starting with the issue 2 (see below), so free scan would consider +02 as hours only time zone now. However there is probably a bit more stuff to do:
sebres added on 2026-03-07 11:58:26:
Fixed for 9.x in [a37536d4d7] and [7018ffb43e]. The case without Tcls tzdata can also be tested from build using Still open or known issues (by system TZs only without Tcls tzdata) are:
I am unsure I shall backport it to 8.6, but if yes theoretically it may be possible only partial, because I don't know earlier bison/yacc versions support semantic predicates aka C-condition in token (don't remember whether tclDate will be generated with newer bison than 3.8.1). | ||||
