Platform: sparc solaris 8, Sun c compiler
Tcl 8.6 cvs head as of Jan 22, 2009
tclvfs cvs head as of Jan 22, 2009
(snapshot files from activestate ftp site)
After building and installing the tcl cvs, I then built and ran the test suite for tclvfs. The following errors are reported:
==== vfsFtp-1.1 mount and cd FAILED
==== Contents of test case:
vfs::ftp::Mount ftp://ftp.ucsd.edu/pub/alpha/ local
cd local
cd tcl
set result [file tail [pwd]]
vfs::unmount local
set result
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: can't read "_unmountCmd(/vol/tclsrcsol/tcl86/tclvfs/unix/local/t
cl/local)": no such element in array
while executing
"uplevel \#0 $_unmountCmd($norm) [list $norm]"
(procedure "vfs::unmount" line 4)
invoked from within
"vfs::unmount local"
("uplevel" body line 6)
invoked from within
"uplevel 1 $script"
---- errorCode: TCL READ VARNAME
---- Test cleanup failed:
can't read "pwd": no such variable
---- errorInfo(cleanup): can't read "pwd": no such variable
while executing
"cd $pwd"
("uplevel" body line 2)
invoked from within
"uplevel 1 $cleanup"
---- errorCode(cleanup): TCL LOOKUP VARNAME
==== vfsFtp-1.1 FAILED
==== vfsFtp-1.2 mount and glob FAILED
==== Contents of test case:
glob -nocomplain -directory local/tcl vfsTest.tcl
---- Result was:
local/tcl/vfsTest.tcl
---- Result should have been (exact matching):
vfsTest.tcl
==== vfsFtp-1.2 FAILED
==== vfsFtp-1.3 mount and source FAILED
==== Contents of test case:
set f [open local/tcl/vfsTest.tcl r]
set data [read $f]
close $f
set data
---- Result was:
return "This was returned from a remote file"
---- Result should have been (exact matching):
This was returned from a remote file
==== vfsFtp-1.3 FAILED
vfsUrl.test
couldn't read file "../library/vfsUrl.tcl": no such file or directory
With the latest CVS head (dated May 19, 2009), the test suite now completely fails to execute. The error is:
PATH="." /vol/tclsrcsol/tcl86/tcl/unix/tclsh `echo ../tests/all.tcl`
couldn't read file "./vfs.tcl": no such file or directory
while executing
"source ./vfs.tcl"
("package ifneeded vfs 1.4.1" script)
invoked from within
"package require vfs 1.4"
(file "../tests/all.tcl" line 35)
gmake: *** [test] Error 1
$ $ ls ../tests
CVS vfs.test vfsFtp.test vfsUrl.test
all.tcl vfsArchive.test vfsTar.test vfsZip.test
Notice that there is no vfs.tcl - it is called vfs.test . However, there is no reference to "vfs.tcl" in any file in ../tests directory.
If I just execute /vol/tclsrcsol/tcl86/tcl/unix/tclsh ../tests/all.tcl by itself, the test suite does run, but errors similar to what was reported here previously are generated.
Both of these conditions continue to exhibit theirselves using the latest CVS heads of tclvfs and tcl.
Okay, the first error is that _unmountCmd is an array that is now created in ::vfs . In the vfs::unmount command, the array is accessed, unqualified, through an uplevel \#0 - the error seems to indicate that the variable isn't accessible from that stack level.