[Python-Dev] Getting importlib into the standard library for 3.1 (original) (raw)
Brett Cannon brett at python.org
Thu Jan 8 22:02:28 CET 2009
- Previous message: [Python-Dev] Getting importlib into the standard library for 3.1
- Next message: [Python-Dev] Getting importlib into the standard library for 3.1
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Thu, Jan 8, 2009 at 12:57, Paul Moore <p.f.moore at gmail.com> wrote:
2009/1/8 Brett Cannon <brett at python.org>:
Thanks, Paul! I changed it to os.getcwd() since that's what nt exposes. Ta. I wasn't sure os.getcwd() returned a full pathname. The only difference between the importlib results and the normal ones seems to be that with importlib, testmultiprocessing is skipped, whereas with the normal import, it fails. The importlib result is testmultiprocessing skipped -- No module named test.testsupport
Well, that should fail since test.test_support doesn't exist in Python 3.0.
where the normal result is
testmultiprocessing Traceback (most recent call last): File "", line 1, in File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 342, in main Traceback (most recent call last): File "", line 1, in File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 342, in main prepare(preparationdata) prepare(preparationdata) File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 451, in prepare file, pathname, etc = imp.findmodule(mainname, dirs) ImportError: No module named File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 451, in prepare file, pathname, etc = imp.findmodule(mainname, dirs) ImportError: No module named Traceback (most recent call last): File "", line 1, in File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 342, in main prepare(preparationdata) File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 451, in prepare file, pathname, etc = imp.findmodule(mainname, dirs) ImportError: No module named Traceback (most recent call last): File "", line 1, in File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 342, in main prepare(preparationdata) File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 451, in prepare file, pathname, etc = imp.findmodule(mainname, dirs) ImportError: No module named Traceback (most recent call last): File "", line 1, in File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 342, in main prepare(preparationdata) File "C:\Apps\Python30\lib\multiprocessing\forking.py", line 451, in prepare file, pathname, etc = imp.findmodule(mainname, dirs) ImportError: No module named test testmultiprocessing crashed -- <class 'EOFError'>: My command line was \Apps\Python30\python.exe -c "import sys; sys.argv = ['', 'testpkg', 'testpydoc', 'testshlex', 'testpep263', 'testdistutils', 'testlib2to3', 'testpep3120', 'testimport']; from test.regrtest import main; main(exclude=True)"
This looks like test_subprocessing tries to snag some detail about what module main is based on the first value of sys.argv.
-Brett
- Previous message: [Python-Dev] Getting importlib into the standard library for 3.1
- Next message: [Python-Dev] Getting importlib into the standard library for 3.1
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]