-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Allow creating requirements.txt files without dev-packages #942
Comments
I think we could add a method that doesn't add dev packages tot he requirements file. It's tough because normally you'd just have everything in your requirements.txt or maybe had two for production and dev dependencies. The reason |
Yeah, but you get the same result if you depend on
Yeah, it's pretty common practice to have separate |
@tuukkamustonen I think if you prefer using piptools with pip-compile directly you are certainly able to do that, pipenv uses pip-tools to build lockfiles so technically you can do that yourself, if you like. If you don't see the difference between pipenv and using pip-compile from pip-tools then you likely wont get anything out of using pipenv. |
@tuukkamustonen |
@techalchemy Wasn't aware of the internal use of I'm not sure what you mean though - pip-tools doesn't support reading @piotr-dobrogost I'm not doing that for libraries (that I use as dependency in other projects) - merely for the final deliverables (web apps, in my case) that I deploy to remote servers. |
Related – #916 (feature request: pipenv lock -r without the dev packages) |
There is indeed a --deploy option now for not installing dev packages. |
@erinxocon Ok so my initial assumption:
Was not correct. The above line does install dev packages. So it actually requires
Should it be updated? Also, this ticket was about supporting dev-package exclusion in |
The documentation is out of date. I actually knew we had a As for |
So things that show up in
Yields:
Do you mean that it should exclude jinja2 from the output? I will look into PR once I understand how things are supposed to work :|
Can we re-open this ticket then? |
So here's the syntax for the new functionality
Will update the documentation. |
@erinxocon I'm confused. Should it work in 9.0.0? Calling |
@wooyek this was a regression in 9.0.0 and will be fixed in the next release. |
Is it now not possible to generate a requirements.txt with both production and dev dependencies in one file? For context I'm developing inside a Docker container so want to install everything into the system environment not in a virtual env. I've avoided using |
-r -d |
@uranusjr thanks but that creates a requirements file with just the development dependencies. I think the best solution is to use |
To install a set of pinned packages in remote systems, there is:
However, this requires both
Pipfile
andPipfile.lock
to be present, and alsopipenv
to be installed in the target system. It's way more inconvenient than just being able to (maybe first copy package wheel into remote system and) saypip install <mypackage>
(and letting pip to pull in the pinned dependencies specified insetup.py
'sinstall_requires
).(Or is there some benefit in using
pipenv install --system
instead?)To be able to generate pinned
requiremets.txt
that excludes development packages, add--no-dev
option topipenv lock
, that seems to by default include also dev packages. Or maybe even change to default to match that ofpipenv install
, and exclude dev-packages by default?As per https://github.com/kennethreitz/pipenv/issues/209#issuecomment-278185133 this is already supported in code:
Although there is workaround for this need already, supporting it right in the cli would/could be nice.
The text was updated successfully, but these errors were encountered: