Artifacts Associated With Ticket 63941fee4fc984f8
Ticket change [0a1b32dcc7] (rid 258341) by serhiy.storchaka on 2026-10-16 22:05:58:
- cmimetype initialized to: "text/x-fossil-wiki"
- comment initialized to:
Since [17c53b7edd] (the fix for [fccb9f322f]) Tcl_Init() calls TclpSetInitialEncodings() for every interpreter, so creating an interpreter (also with Thread or Tk) resets the system encoding to the one from the environment: <verbatim> encoding system koi8-r interp create a encoding system ;# utf-8 (8.6: koi8-r) </verbatim> The repeated detection is also what calls setlocale() in parallel threads in [c35e347c6f]. It is only needed while the earlier detection failed (the encoding files were not found yet).
- foundin initialized to: "9.0.5, 9.1.0"
- login: "serhiy.storchaka"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- severity initialized to: "Minor"
- status initialized to: "Open"
- submitter initialized to: "serhiy.storchaka"
- subsystem initialized to: "44. UTF-8 Strings"
- title initialized to:
interp create resets the system encoding set by encoding system
- type initialized to: "Bug"
Ticket change [d4ba36ed13] (rid 258349) by serhiy.storchaka on 2026-10-16 22:12:02:
- icomment:
Proposed fix in branch [/timeline?r=initial-encoding-once|initial-encoding-once]: TclpSetInitialEncodings() sets the encoding from the environment only until it succeeds, so later Tcl_Init() calls do not reset it and do not call setlocale() again. The retry for [fccb9f322f] still works (unixInit-3.2). Test encoding-31.5.
- login: "serhiy.storchaka"
- mimetype: "text/x-fossil-wiki"
- icomment:
Ticket change [f3d1ce6b6c] (rid 258379) by jan.nijtmans on 2026-10-17 06:46:04:
- assignee changed to: "aku"
- closer changed to: "nobody"
- comment changed to:
Since [17c53b7edd] (the fix for [fccb9f322f]) Tcl_Init() calls TclpSetInitialEncodings() for every interpreter, so creating an interpreter (also with Thread or Tk) resets the system encoding to the one from the environment: <verbatim> encoding system koi8-r interp create a encoding system ;# utf-8 (8.6: koi8-r) </verbatim> The repeated detection is also what calls setlocale() in parallel threads in [c35e347c6f]. It is only needed while the earlier detection failed (the encoding files were not found yet).
- icomment:
I agree with this. Please go ahead merging this!
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
Ticket change [651c1cbbd3] (rid 258442) by serhiy.storchaka on 2026-10-17 07:25:45:
- icomment:
Merged into main in [00b1026efe] and into 9.0 in [27f849b6b3].
- login: "serhiy.storchaka"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"
- icomment:
Ticket change [7d1c2071a0] (rid 259954) by serhiy.storchaka on 2026-10-22 17:19:27:
- closedate changed to: "2461330.809553079"
- closer changed to: "serhiy.storchaka"
- login: "serhiy.storchaka"