pipenv clean [perhaps] should not update Pipfile.lock
See original GitHub issueOn one hand, help for clean command suggests that the lock file will only be read:
> pipenv clean --help
Usage: pipenv clean [OPTIONS]
Uninstalls all packages not specified in Pipfile.lock.
...
On the other, in my case, the log suggests that the lock file got updated:
> pipenv clean -v
Pipfile.lock (e3d06d) out of date, updating to (327524)…
Locking [dev-packages] dependencies…
✔ Success!
Using pip: -i https://pypi.org/simple --extra-index-url https://[private]/pypi/
Using pip: -i https://pypi.org/simple --extra-index-url https://[private]/pypi/
Using pip: -i https://pypi.org/simple --extra-index-url https://[private]/pypi/
ROUND 1
Current constraints:
...
Clearly I don’t quite understand the internal mechanics of pipenv. Overall this seems inconsistent.
TBH, it is quite possible that my lock file did not match the pip file, as I was messing out with some dependencies and could have forgotten to lock dep list. I’m not quite sure what would be the right thing for the command to do in this case.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:5 (3 by maintainers)
Top Results From Across the Web
How to handle `pip install` inside a pipenv environment (not ...
First, let's clarify that the pipenv install command is just a wrapper for pip . If you install with --verbose , you'll see...
Read more >Pipenv & Virtual Environments - Python Packaging Authority
This tutorial walks you through installing and using Python packages. It will show you how to install and use the necessary tools and...
Read more >Pipenv — Dan's Cheat Sheets 1 documentation
Just run “pipenv install [-r requirementsfile]” and it'll see that there's no Pipfile but a requirements file, and will generate a new Pipfile...
Read more >Simplify Your Python Developer Environment | by Mason Egger
The Pipfile.lock is referenced whenever you attempt to do a pipenv install with a specified Pipfile. If the hashes in the lock file...
Read more >pipenv Documentation - Read the Docs
Pipenv uses two files to do this: Pipfile and Pipfile.lock (which will look familiar ... Pipenv will install version 1.2 and any minor...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
There is an API discussion to have here but mostly locking happened because your Pipfile was out of sync with your lockfile. This is a side effect of some other parts of the code, honestly, and if you haven’t locked yet then the new packages obviously haven’t been installed. Clean probably shouldn’t require this— it should just use the current lockfile
I encountered this as well, and it’s non-intuitive