Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2026-05-16
15:58 • Ticket [4f06d7ca08] package require in secondary interpreters fails for static p... artifact: 808387a34b user: apnadkarni
15:54
Fix [6094de399d] and [4f06d7ca08] - registry/dde packages in static builds. check-in: 624bac9741 user: apnadkarni tags: core-9-0-branch
2026-05-15
11:18 • Wiki page "branch/bug-4f06d7ca" artifact: cde1f32a15 user: dkf
2026-05-10
05:49 • New ticket [6094de399d] registry and dde commands are available in static builds... artifact: bd3c893116 user: apnadkarni
2026-05-09
05:22 • Ticket [4f06d7ca08] package require in secondary interpreters fails for static p... artifact: b2f4071bde user: apnadkarni
05:20 • New ticket [4f06d7ca08]. artifact: eb830488a3 user: apnadkarni

package require in secondary interpreters fails for static packages

Open4f06d7ca089e8a6d2321cdf59da48be09654013dCreated 208 days agoUpdated 200 days ago
Descriptionmarkdown2026-05-09 05:20:33

The failure is demonstrated as below (this needs to be a static Tcl shell)

% info pat
8.6.18
% package req registry
1.3.5
% interp create ip
ip
% ip eval {package require registry}
can't find package registry
% ip eval {load {} Registry}
% exit

The original report came from @morganw on the chat with the script below that does not print 1 2 3 in a static shell.

set scriptDir [file dirname [file normalize [info script]]]
set libDir [file join $scriptDir "lib"]
lappend auto_path $libDir

package require Thread

set workerThread [thread::create [subst {
    lappend auto_path $libDir
    package require registry
    thread::wait
}]]

thread::send -async $workerThread { list 1 2 3 } result
vwait result
puts $result
Referenced by1
apnadkarnimarkdown2026-05-09 05:22:26

As far as I can tell, this bug is present in Tcl versions that go way back and a workaround is to "load {} Registry" (or appropriate static package) so I do not feel this need hold up 8.6.18 or change its status as the "final" 8.6 release.

apnadkarniplain2026-05-16 15:58:40
Fixed for 9.0 in [624bac9741].

9.1 fix proposed in TIP 755.
Log in (anonymous is fine) to add a comment.