TCL Shell works but Komodo Shell does not

Posted by jakeb on 2017-09-18 13:10

The following script called test1.tcl works well from a tclsh command line.

# test1.tcl
set matchResults [exec /usr/bin/neo4j-client --non-interactive --eval "match (n) return n;" localhost]
puts "Success! \n\n $matchResults \n"

% source test1.tcl
Success!

"n"
"(:LibCell{library:""Nangate45"",name:""AND2_X1""})"
"(:CellPins{name:""CellPins""})"
"(:CellModes{mutuallyExclusive:true,name:""CellModes""})"
"(:CellEvents{mutuallyExclusive:true,name:""CellEvents""})"
"(:CellPin{capacitance:9.999000,name:""A1"",direction:""input""})"
"(:CellPin{capacitance:9.999000,name:""A2"",direction:""input""})"
"(:CellPin{name:""ZN"",direction:""output""})"
"(:CellPin{name:""VDD"",direction:""pg""})"
"(:CellPin{name:""VSS"",direction:""pg""})"

But the same script fails when running in the Kodomo Tcl Shell

Tcl 8.6.5 interactive shell
To use Tk, type 'package require Tk'
% source test1.tcl
Can't open /dev/tty: No such device or address

What's wrong?

Thanks,
Jake

grahams
ActiveState Staff
Wed, 2017-09-20 08:50

This is a Linux error message, it's not coming from Tcl.

This is the trigger:
exec /usr/bin/neo4j-client
exec spawns a new process that inherits the current environment. When it's spawned under Komodo, the process doesn't know about a terminal window because the Komodo editing viewer isn't a terminal.

Check your Komodo documentation and/or the Komodo forums for usage tips. You probably need to set the "debug in separate console" option.