Issue415933
Created on 2001-04-13.17:04:03 by bckfnn, last changed 2001-06-14.19:42:25 by pedronis.
History | |||
---|---|---|---|
Date | User | Action | Args |
2001-04-13 17:04:03 | bckfnn | create |
Created on 2001-04-13.17:04:03 by bckfnn, last changed 2001-06-14.19:42:25 by pedronis.
Messages | |||
---|---|---|---|
msg296 (view) | Author: Finn Bock (bckfnn) | Date: 2001-04-13.17:04:03 | |
[Posted to jython-dev by Kexx] Here's a short failure scenario: -- module Main.py in root/current package -- # commented -- from amod.A import A from bmod.B import B B().bfunc() -- end Main.py -- -- module A.py in package/directory apkg -- class A: def afunc(self): return "kermits" -- end A.py -- -- module B.py in package/directory bpkg -- from apkg.A import A class B: def bfunc(self): print A().afunc() -- end B.py -- I also have 2 empty __init__.py files (one for apkg, the other for = bpkg). Now, "jython Main.py" works just fine ("kermits" is printed). Here's the output from "jythonc --deep" at compile time: -- start -- E:\projects\jytest\2>jythonc --deep Main.py processing Main processing bpkg.B processing apkg.A processing bpkg.__init__ Next, we go to "./jpywork" and do a "java Main" and get: -- start -- Java Traceback: Traceback (innermost last): File "E:\projects\jytest\2\Main.py", line 0, in main File "E:\projects\jytest\2\bpkg\B.py", line 0, in main ImportError: no module named apkg -- end -- |
|||
msg297 (view) | Author: Samuele Pedroni (pedronis) | Date: 2001-06-14.19:42:25 | |
Logged In: YES user_id=61408 Fixed. Oddly enough, it was a core problem: at some point the None used as mark in sys.modules to speed- dup relative imports, were blindly returned by imports instead of raising proper import errors. |
History | |||
---|---|---|---|
Date | User | Action | Args |
2001-04-13 17:04:03 | bckfnn | create |
Supported by Python Software Foundation,
Powered by Roundup