From: SourceForge.net <no...@so...> - 2005-10-24 21:17:01
|
Bugs item #1256506, was opened at 2005-08-11 05:29 Message generated for change (Comment added) made by blfgomes You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112867&aid=1256506&group_id=12867 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Core Group: None Status: Open Resolution: None Priority: 5 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: Importing directory module with 12+ char name fails in 2.2a1 Initial Comment: Importing a module, which is implemented as a directory with a __init__.py, fails if directory name is 12 characters or longer. If the module is a regular .py file importing it works ok. See the listing below for an example. Bug seems to be specific to Jython 2.2 alpha 1 since importing works ok with Jython 2.1 and Python 2.4. I'm using Sun Java 1.5 but the problem appeared also with Java 1.4. --------8<----------------8<---------------- $ uname CYGWIN_NT-5.1 $ java -version java version "1.5.0_04" Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_04-b05) Java HotSpot(TM) Client VM (build 1.5.0_04-b05, mixed mode, sharing) $ ls -lR .: total 32 drwxr-xr-x 2 peke None 0 Aug 11 09:35 mod_dir__11/ drwxr-xr-x 2 peke None 0 Aug 11 09:58 mod_dir___12/ -rw-r--r-- 1 peke None 8 Aug 11 09:58 mod_file_11.py -rw-r--r-- 1 peke None 8 Aug 11 09:58 mod_file__12.py ./mod_dir__11: total 16 -rw-r--r-- 1 peke None 8 Aug 11 09:57 __init__.py ./mod_dir___12: total 16 -rw-r--r-- 1 peke None 8 Aug 11 09:58 __init__.py $ /cygdrive/c/jython-2.2a1/jython.bat Jython 2.2a1 on java1.5.0_02 (JIT: null) Type "copyright", "credits" or "license" for more information. >>> import mod_file_11 >>> import mod_file__12 >>> import mod_dir__11 >>> import mod_dir___12 Traceback (innermost last): File "<console>", line 1, in ? ImportError: no module named mod_dir___12 >>> ---------------------------------------------------------------------- Comment By: Bruno Gomes (blfgomes) Date: 2005-10-24 19:17 Message: Logged In: YES user_id=1367276 I submitted a patch for this, take a look at: http://sourceforge.net/tracker/?func=detail&atid=312867&aid=1336768&group_id=12867 ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2005-08-11 05:34 Message: Logged In: NO The difference in Java versions when running "java -version" (1.5.0_04) and starting Jython (1.5.0_02) was due to not updating jython.bat after a Java update. Tested now also after the update with same results. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112867&aid=1256506&group_id=12867 |