Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pip-compile generates "-e /path/to/local/dir" in requirements.txt #325

Closed
blampe opened this issue Feb 29, 2016 · 4 comments
Closed

pip-compile generates "-e /path/to/local/dir" in requirements.txt #325

blampe opened this issue Feb 29, 2016 · 4 comments

Comments

@blampe
Copy link

blampe commented Feb 29, 2016

Similar use case as in #176 and possibly #223 -- I'm trying to eliminate duplication between setup.py and requirements.in. Here's a small repro:

$ cat requirements.in
-e .
$ cat setup.py
from setuptools import find_packages, setup

setup(
    name='foobar',
    install_requires=[
        'contextlib2',
    ],
)
$ pip --version
pip 7.1.0 from /Users/blampe/src/pip-tools-test/env/lib/python2.7/site-packages (python 2.7)
$ pip-compile --version
pip-compile, version 1.6
$ pip-compile --no-index
#
# This file is autogenerated by pip-compile
# Make changes in requirements.in, then run this to update:
#
#    pip-compile --no-index requirements.in
#
-e file:///Users/blampe/src/pip-tools-test
contextlib2==0.5.1

I'd expect this to only include contextlib2 but it also has an unportable "-e" path. This causes errors when trying to install from requirements.txt on any other machine.

@ryanhiebert
Copy link
Contributor

FWIW, I would expect it to keep the -e ., because the foobar package still needs to be installed. For my own uses, it still needs to be installed because I have the package in a src directory (so that it's not importable without installation), and because it installs a script. It just needs to remain a relative path so that it doesn't break when installed in a different repository, machine, etc.

@blampe
Copy link
Author

blampe commented Apr 6, 2016

Yeah totally agree, I have a similar use case. The real problem is that it's an absolute path instead of relative. Feel free to close this if it's a dupe of #204.

@davidovich
Copy link
Contributor

Closing as duplicate to #204, let's continue there.

@atugushev
Copy link
Member

atugushev commented Nov 10, 2019

The known workaround is -e file:.#egg=foobar . See #204 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants