From: Russell O. <ro...@uw...> - 2014-10-09 19:49:59
|
The command http::geturl -channel is broken on MacOS 10.9.5 (and likely other versions). Transfers fail while writing to the channel with "resource temporarily unavailable". Transfers seem to work if -channel not specified. I have appended a simple example and posted a bug report <http://core.tcl.tk/tcl/tktview/ed29c4da21f4c0a7858a0f5ae4aae20dd42fc818> If anyone knows of a reasonable workaround, that would be great. I can almost certainly use a progress callback to manually write the data (and thus avoid using a channel) but unless there is some way to purge the data from the state array after writing it, that would fail on large files. (I see how to read the data, but not purge it.) 8.5.16 does fix the menu crashing bug that prevented me from updating past 8.5.11, but unfortunately this new bug is a show-stopper. -- Russell package require http set outname "saturn.jpg" set url "http://apod.nasa.gov/apod/image/1409/saturnequinox_cassini_7227.jpg" set out [open "temp" w] set token [::http::geturl $url -channel $out] close $out package require http On MacOS with ActiveState Tcl 8.5.16 I see: Error in startup script: error reading "sock8": resource temporarily unavailable while executing "::http::geturl $url -channel $out" invoked from within "set token [::http::geturl $url -channel $out]" (file "tcl http example.tcl" line 6) |