question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Python install line standard

See original GitHub issue

Can we establish a standard for how we do the whole python setup.py dance?

Please vote by posting a comment with the corresponding number. Majority after 1 week wins?

  1. python setup.py install --single-version-externally-managed --record=record.txt
  2. python setup.py install --single-version-externally-managed --root=/
  3. python setup.py install --old-and-unmanageable
  4. python -m pip install --no-deps .
  5. pip install --no-deps .

I give up on strikethrough. 4 is out, due to error (https://travis-ci.org/conda-forge/staged-recipes/jobs/127374916#L405)

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:51 (47 by maintainers)

github_iconTop GitHub Comments

5reactions
msarahancommented, May 4, 2016

This seems core enough that we might want to build it right into conda/conda-build. It might make pip-installed packages work a little better with conda. Thanks for your insight, @minrk.

2reactions
minrkcommented, May 4, 2016

I’d go for 5. 4 also works if --ignore-installed is added. I think 4 doesn’t work as-is because python -m seems to add . to sys.path, whereas pip alone doesn’t. That difference was awfully surprising.

The disadvantage of 1-3 is that they all assume setuptools is imported in setup.py, whereas pip should do the right thing in both cases (mainly by importing setuptools itself). If a package doesn’t use setuptools, then you have to use setup.py install without the extra args in the conda recipe, and then if it starts importing setuptools you have to make sure that the recipe changes the setup.py args at the same time. If you use pip, the command in the recipe wouldn’t change.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Installing Packages - Python Packaging User Guide - Python.org
Requirements for Installing Packages. Ensure you can run Python from the command line. Ensure you can run pip from the command line ·...
Read more >
4. Using Python on Windows — Python 3.11.1 documentation
The Python Launcher for Windows will be installed according to the option at the bottom of the first page. The standard library, test...
Read more >
Download Python - Python.org
Looking for 3rd party Python modules? · You can view the standard documentation online, or you can download it in HTML, PostScript, PDF...
Read more >
Installing Python Modules — Python 3.11.1 documentation
The standard packaging tools are all designed to be used from the command line. The following command will install the latest version of...
Read more >
Installing Python Modules (Legacy version) — Python 3.11.1 ...
Most Linux distributions include Python as a standard part of the system, so prefix and exec-prefix are usually both /usr on Linux. If...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found