#1494 closed defect (somebody else's problem)

'python setup.py install' does not install all dependencies

Reported by: canercandan Owned by: canercandan
Priority: major Milestone: undecided
Component: code Version: 1.8.2
Keywords: setuptools install Cc:
Launchpad Bug:

Description (last modified by zooko)

I have made the test on an Ubuntu 10.04 and 11.04 distributions.

When I install tahoe-lafs using the sources with the commands:

python ./setup.py build
python ./setup.py install

not all of the dependencies are correctly installed. Indeed some of them located under support/lib/... are not in /usr/local/python-X.XX/dist-packages/...

So that when I use the command "tahoe" it generates missing dependencies error messages.

Solution: The temporary solution is to manually copy the whole of files and subdirectories located on support/lib/... into /usr/local/python-X.XX/dist-packages/... and then it works fine.

Change History (11)

comment:1 Changed at 2011-08-21T14:53:40Z by davidsarah

  • Component changed from unknown to code
  • Description modified (diff)
  • Keywords setuptools install added
  • Owner changed from nobody to somebody
  • Summary changed from Installation from sources not pretty fine to 'python setup.py install' does not install all dependencies

comment:2 Changed at 2011-08-21T15:18:07Z by davidsarah

Which dependencies are not installed, and what is the full output of python setup.py build and python setup.py install? (Please attach it.)

comment:3 Changed at 2011-08-21T15:37:25Z by davidsarah

... and also the output of "which tahoe" and "tahoe --version-and-path" after the install.

comment:4 Changed at 2011-08-21T16:00:31Z by davidsarah

Oh, before doing the above tests, please delete or move aside the directories you copied into /usr/local/python-X.XX/dist-packages , and do make clean in the Tahoe source directory.

comment:5 Changed at 2011-08-26T21:51:31Z by davidsarah

  • Owner changed from somebody to canercandan

Waiting for more information from canercandan.

comment:6 follow-up: Changed at 2013-08-27T11:30:13Z by zooko

  • Description modified (diff)

Even if canercandan doesn't give more information, I now understand that python setup.py install doesn't install dependencies, only the main package. This is unlike easy_install allmydata-tahoe and pip install allmydata-tahoe and unlike just doing python setup.py build and running the software from the current directory, as is recommended in quickstart.rst. All of those three options will automatically resolve dependencies. See, for example, sel's recent bug report: #2063.

I'm leaving this ticket open. To fix it, switch our build system to a tool which automatically resolves dependencies when you run python setup.py install. (Note: I'm not aware of any build tool that already does this for you, so I guess you would have to create a bespoke tool for Tahoe-LAFS or else contribute a patch to some tool like setuptools and then use it in Tahoe-LAFS.)

comment:7 Changed at 2013-08-27T12:04:27Z by zooko

According to dstufft, python setup.py install is supposed to install dependencies! I don't know why it doesn't, but it might have something to do with #2044.

The next step on this ticket is to write a test script that someone will eventually wire into the buildbot, which runs python setup.py install and then reports failure if a dependency didn't get installed. There are currently some tests of similar things, such as TestOldDep (comment:8:ticket:2049) which reports failure if the build process doesn't install a newer dep to override a too-old-for-our-requirements older dep. So you could copy the way that test is implemented (for now).

comment:8 Changed at 2013-08-27T12:16:19Z by daira

See also #2063.

comment:9 in reply to: ↑ 6 Changed at 2013-08-27T12:21:34Z by daira

Replying to zooko:

Even if canercandan doesn't give more information, I now understand that python setup.py install doesn't install dependencies, only the main package. This is unlike easy_install allmydata-tahoe and pip install allmydata-tahoe and unlike just doing python setup.py build and running the software from the current directory, as is recommended in quickstart.rst. All of those three options will automatically resolve dependencies.

I believe that's mistaken. All of the "build" procedures resolve dependencies, but none of the "install" procedures (excluding installing OS packages) do.

Version 0, edited at 2013-08-27T12:21:34Z by daira (next)

comment:10 Changed at 2013-08-27T12:31:51Z by daira

Oh, maybe pip install does try to install dependencies (because it overrides setuptools' default dependency resolution and handles that itself), but then it hits #2032 unless the Nevow requirement is already met.

comment:11 Changed at 2020-01-13T20:37:35Z by exarkun

  • Resolution set to somebody else's problem
  • Status changed from new to closed

pip install tahoe-lafs works now and is the preferred and supported way to install Tahoe-LAFS.

Note: See TracTickets for help on using tickets.