From: <no...@so...> - 2002-07-31 15:01:39
|
Bugs item #589148, was opened at 2002-07-31 15:01 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112867&aid=589148&group_id=12867 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Thorstein Thorsteinsson (thorstein) Assigned to: Nobody/Anonymous (nobody) Summary: Syntax error -> jython infinite loop Initial Comment: The following ex.py: ------------------ a = 1 if a = 1: print "Success!" ------------------ leads to an infinite loop somewhere in the Jython interpreter. This only happens when the code is executed non-interactively, an interactive session correctly signals the syntax error in line 2. Output from jython -v ex.py ---------------------------------------- jython -v ex.py import: 'exceptions' as org.python.core.exceptions in builtin modules import: 'site' as /home/tthorste/jython- 2.1/Lib/site$py.class import: 'sys' as sys in builtin modules import: 'os' as org.python.modules.os in builtin modules import: 'javaos' as /home/tthorste/jython- 2.1/Lib/javaos$py.class import: 'java' as java package import: 'File' as java class import: 'BufferedReader' as java class import: 'InputStreamReader' as java class import: 'IOException' as java class import: 'javapath' as /home/tthorste/jython- 2.1/Lib/javapath$py.class import: 'System' as java class import: 'UserDict' as /home/tthorste/jython- 2.1/Lib/UserDict$py.class import: 'string' as /home/tthorste/jython- 2.1/Lib/string$py.class import: 'strop' not found (=> ImportError) import: 're' as /home/tthorste/jython- 2.1/Lib/re$py.class import: 'sre' as /home/tthorste/jython- 2.1/Lib/sre$py.class import: 'sre_compile' as /home/tthorste/jython- 2.1/Lib/sre_compile$py.class import: '_sre' as org.python.modules._sre in builtin modules import: 'sre_constants' as /home/tthorste/jython- 2.1/Lib/sre_constants$py.class import: 'sre_parse' as /home/tthorste/jython- 2.1/Lib/sre_parse$py.class import: 'copy_reg' as /home/tthorste/jython- 2.1/Lib/copy_reg$py.class import: 'types' as org.python.modules.types in builtin modules import: 'thread' as org.python.modules.thread in builtin modules import: 'sitecustomize' not found (=> ImportError) ---------------------------------------- then jython hangs, using lots of CPU: > ps -ef | grep java ... /usr/java1.2/jre/bin/../bin/sparc/native_threads /java -Dpython.home=/home/... ---------------------------------------- I'm running on Solaris 2.8 with jre 1.2 version 2.1 of Jython. > jython --version Jython 2.1 on java (JIT: sunwjit) > (Jython downloaded on July 15th.) ---------------------------------------- But thanks for doing a great job. Thorstein ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112867&aid=589148&group_id=12867 |