|
From: <bc...@wo...> - 2001-02-02 15:47:07
|
[Adam Burke] >Odd problem. Jython console started with no parameters fails with an >"IOError - File not found -". However the problem goes away when the >interpreter is started with a script param or started with the -v = >option. > >Compaq Tru64 Unix >uname -a >OSF1 supanova V4.0 1229 alpha=20 > >Trace / config > >prompt>jython >Traceback (innermost last): > (no code object) at line 0 >IOError: File not found - (No such file or directory) >supanova /usr/users/supastar/gway/bin =3D> jython -v >import: 'exceptions' as org.python.core.exceptions in builtin modules >Jython 2.0 on java1.2.2-1 (JIT: jit_122) >import: 'site' as /usr/local/jython-20/Lib/site.py >import: 'sys' as sys in builtin modules >import: 'os' as org.python.modules.os in builtin modules >import: 'javaos' as /usr/local/jython-20/Lib/javaos.py >import: 'java' as java package >import: 'File' as java class >import: 'javapath' as /usr/local/jython-20/Lib/javapath.py >import: 'System' as java class >import: 'sitecustomize' not found (ImportError) >Type "copyright", "credits" or "license" for more information. >>>> ^D >supanova /usr/users/supastar/gway/bin =3D> java -fullversion >java full version "J2SDK.v.1.2.2:09/30/1999-19:00" >supanova /usr/users/supastar/gway/bin =3D> whence java >/usr/opt/java122/bin/java >supanova /usr/users/supastar/gway/bin =3D> java -version >java version "1.2.2-1" >Classic VM (build J2SDK.v.1.2.2:09/30/1999-19:00, native threads, = >jit_122) =20 > >I've also tried it with jdk118 on this platform. I only see the = >problem on >this platform. It looks like the "-" convention for stdin is not being >recognised. No, I don't think so: i:\java\jython.cvs\org\python\core>jython xxx Traceback (innermost last): (no code object) at line 0 IOError: File not found - xxx (The system cannot find the file specified) So the '-' in the error text is part of the exception text. Instead it seems as if an empty string is passed to java as an argument. >I should be able test patches / configuration changes / >suggestions if you don't have access to this env, though I haven't got = >a lot >of time to give to it. Any suggested starting points? The generated script use "$@" to pass the script arguments to java. If no arguments are supplied, perhaps Tru64 will pass it as "". Try to change the "jython" script to use some other way of passing the args: java .... org.python.util.jython $1 $2 $3 $4 $5 This is too naive for production use, but I think it can help illustrate where the problem is. Changing the shell in the first line of the script might also help. If none of that helps, try to enter the full java command from the script on the command line, but with any args: java -Dpython.home=.. -classpath ".." org.python.util.jython Only if that also fails will I believe there is a problem with the java VM you are using. regards, finn |