#1272 closed defect (cannot reproduce)

'ImportError: No module named pkg_resources' errors from runner tests under Windows 7 -64 Bit

Reported by: pgrunwald Owned by: pgrunwald
Priority: major Milestone: undecided
Component: packaging Version: 1.8.0
Keywords: win64 test setuptools Cc:
Launchpad Bug:

Description (last modified by davidsarah)

Windows 7 Ultimate 64-Bit Python 2.6.6 (r266:84297, Aug 24 2010, 18:13:38) [MSC v.1500 64 bit (AMD64)] on win32

(snip SKIPPED and TODO tests)
=============================================================================== [FAIL]: allmydata.test.test_runner.BinTahoe?.test_path

Traceback (most recent call last):

    File "g:\allmydata-tahoe-1.8.0-r4803\src\allmydata\test\test_runner.py", line

90, in _cb

    self.failUnlessEqual(rc_or_sig, 0, str(res))

twisted.trial.unittest.FailTest?: (, 'Traceback (most recent call last):\r\n F ile "g:
allmydata-tahoe-1.8.0-r4803
support
Scripts
tahoe.pyscript", line 6,

    in <module>\r\n from pkg_resources import load_entry_point\r\nImportError: N

o module named pkg_resources\r\n', 1) not equal: a = 1 b = 0

=============================================================================== [FAIL]: allmydata.test.test_runner.BinTahoe?.test_run_with_python_options

Traceback (most recent call last):

    File "g:\allmydata-tahoe-1.8.0-r4803\src\allmydata\test\test_runner.py", line

149, in _cb

    self.failUnlessEqual(rc_or_sig, 0, str(res))

twisted.trial.unittest.FailTest?: (, 'Traceback (most recent call last):\r\n F ile "g:
allmydata-tahoe-1.8.0-r4803
support
Scripts
tahoe.pyscript", line 6,

    in <module>\r\n from pkg_resources import load_entry_point\r\nImportError: N

o module named pkg_resources\r\n', 1) not equal: a = 1 b = 0

=============================================================================== [FAIL]: allmydata.test.test_runner.BinTahoe?.test_unicode_arguments_and_output

Traceback (most recent call last):

    File "g:\allmydata-tahoe-1.8.0-r4803\src\allmydata\test\test_runner.py", line

137, in _cb

    self.failUnlessIn("Unknown command: "+tricky_out, out)

twisted.trial.unittest.FailTest?: 'Unknown command: \xe2\x98\xa1' not in =============================================================================== [FAIL]: allmydata.test.test_runner.BinTahoe?.test_version_no_noise

Traceback (most recent call last):

    File "g:\allmydata-tahoe-1.8.0-r4803\src\allmydata\test\test_runner.py", line

165, in _cb

    self.failUnlessEqual(rc_or_sig, 0, str(res))

twisted.trial.unittest.FailTest?: (, 'Traceback (most recent call last):\r\n F ile "g:
allmydata-tahoe-1.8.0-r4803
support
Scripts
tahoe.pyscript", line 6,

    in <module>\r\n from pkg_resources import load_entry_point\r\nImportError: N

o module named pkg_resources\r\n', 1) not equal: a = 1 b = 0

Ran 828 tests in 809.711s

FAILED (skips=15, expectedFailures=3, failures=4, successes=806) }}}

Change History (12)

comment:1 Changed at 2010-11-28T01:36:48Z by davidsarah

  • Description modified (diff)
  • Keywords win64 added; 64-bit removed
  • Milestone changed from 1.8.1 to undecided

comment:2 follow-up: Changed at 2010-11-28T01:40:01Z by davidsarah

  • Component changed from unknown to packaging
  • Keywords setuptools added
  • Owner changed from nobody to somebody

This looks like setuptools is not installed, or not being found. But why wasn't the bundled zetuptoolz used in that case?

comment:3 in reply to: ↑ 2 Changed at 2010-11-28T02:49:30Z by davidsarah

  • Owner changed from somebody to pgrunwald

Replying to davidsarah:

This looks like setuptools is not installed, or not being found. But why wasn't the bundled zetuptoolz used in that case?

What should happen is that setuptools-0.6c16dev2.egg is copied to support\lib\site-packages by python setup.py build, and then that site-packages directory gets added to the PYTHONPATH variable by the bin\tahoe script. Then the easy-install.pth file in that directory should have a line saying "setuptools-0.6c16dev2.egg", which causes the site module to add that egg to sys.path during the default Python initialization.

I don't think this is supposed to rely on the hack that setuptools installs to site.py. That hack should only change the order of sys.path entries, so the lack of it wouldn't explain pkg_resources not being found at all.

pgrunwald: please list the contents of your <tahoe dir>\support\lib\site-packages directory, as well as the easy-install.pth and setuptools.pth files in that directory.

Also, with the Tahoe distribution as the current directory, what does this give:

set PYTHONPATH=
python -c "import pkg_resources; print pkg_resources.require('setuptools')"

and this:

set PYTHONPATH=support\lib\site-packages
python -c "import pkg_resources; print pkg_resources.require('setuptools')"

and this:

set PYTHONPATH=support\lib\site-packages;support\lib\site-packages\setuptools-0.6c16dev2.egg
python -c "import pkg_resources; print pkg_resources.require('setuptools')"

?

(Please do not install setuptools yet. We'd like to get this working without you having to do that.)

comment:4 Changed at 2010-11-28T03:03:13Z by davidsarah

  • Summary changed from Test errors under Windows 7 -64 Bit to 'ImportError: No module named pkg_resources' errors from runner tests under Windows 7 -64 Bit

comment:5 Changed at 2010-11-28T03:57:44Z by zooko

Dear pgrunwald:

allmydata-tahoe-1.8.0-r4803 is from the beginning of this month. Could you please try again with this:

http://tahoe-lafs.org/source/tahoe-lafs/tarballs/allmydata-tahoe-1.8.0-r4850.zip

comment:6 follow-up: Changed at 2010-11-28T04:07:07Z by pgrunwald

G:\allmydata-tahoe-1.8.0-r4850>python setup.py build
Traceback (most recent call last):
  File "setup.py", line 63, in <module>
    execfile('src/allmydata/_auto_deps.py', adglobals)
IOError: [Errno 2] No such file or directory: 'src/allmydata/_auto_deps.py'}}}

Thnaks,
Paul

comment:7 in reply to: ↑ 6 Changed at 2010-11-28T04:31:07Z by zooko

Replying to pgrunwald:

IOError: [Errno 2] No such file or directory: 'src/allmydata/_auto_deps.py'}}}

Cannot reproduce! Could you check whether there is a file there? There is a file there in the .zip file that I linked to.

comment:8 Changed at 2010-11-29T01:09:20Z by pgrunwald

G:\allmydata-tahoe-1.8.0-r4850\src\allmydata>dir
 Volume in drive G is Scratchpad
 Volume Serial Number is FE5F-F7AE

 Directory of G:\allmydata-tahoe-1.8.0-r4850\src\allmydata

11/27/2010  08:38 PM    <DIR>          .
11/27/2010  08:38 PM    <DIR>          ..
11/27/2010  07:12 PM             8,071 check_results.py
11/27/2010  07:12 PM            22,120 client.py
11/27/2010  08:37 PM    <DIR>          immutable
11/27/2010  07:12 PM           115,900 interfaces.py
11/27/2010  07:12 PM            14,749 node.py
11/27/2010  07:12 PM            11,335 reliability.py
11/27/2010  08:38 PM                31 _appname.py
11/27/2010  07:12 PM            10,255 __init__.py
               7 File(s)        182,461 bytes
               3 Dir(s)  468,197,363,712 bytes free}}}

comment:9 Changed at 2010-11-29T01:17:40Z by davidsarah

It looks like your download of the zip file was incomplete, or it didn't unzip correctly. Please try again, perhaps with different download or unzip tools if you get the same symptoms.

comment:10 Changed at 2010-12-01T02:15:43Z by pgrunwald

  • Resolution set to fixed
  • Status changed from new to closed

Cannot reproduce with 1.8.1 - I got a clean build and passed all tests

comment:11 Changed at 2010-12-01T04:40:40Z by davidsarah

  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening in order to resolve as "cannot reproduce".

comment:12 Changed at 2010-12-01T04:40:53Z by davidsarah

  • Resolution set to cannot reproduce
  • Status changed from reopened to closed
Note: See TracTickets for help on using tickets.