breaking change: invert `lock --no-update` to `lock --update` (or similar)
See original GitHub issue- I have searched the issues of this repo and believe that this is not a duplicate.
- I have searched the documentation and believe that my question is not covered.
Feature Request
Now that https://github.com/python-poetry/poetry/issues/1614 is fixed and released (yay!), I’d like to propose that for v2, there is a breaking change to make Poetry more opinionated and preserve the versions in the lockfile by default, only updating when explicitly asked to (such as with the update
command or some kind of --update
flag to lock
). Doing so follows the patterns in analogous tools like Yarn and Cargo and adheres to the principle of least surprise.
See also the philosophically-related https://github.com/python-poetry/poetry/issues/2370.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:84
- Comments:7
Top Results From Across the Web
Announcing Poetry 1.3.0 | Blog
The lock file format has been changed to better support explicit sources. This change should be mostly transparent for users, as Poetry ...
Read more >python - How to update Poetry's lock file without upgrading ...
There is a specific option for the lock command: poetry lock --no-update. This makes it possible to remove a dependency from pyproject.toml ...
Read more >How can I fix the "Another Update in Progress" WordPress ...
After installing the plugin, proceed to Settings > Fix Another Update in Progress to remove the lock. You should see the “There is...
Read more >TBS TANGO 2 Radio - Team BlackSheep
Modifying it is a matter of screwing in the throttle-lock screw and loosening the other. The rest is changed in the radio configuration...
Read more >MV7 User Guide - Shure Publications
Connect the other end of the Micro-B USB cable to your laptop. ... Settings lock prevents changes to microphone settings from accidental touches....
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 Free
Top 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
+1 for this feature. Our project is pretty big where many folks, with various skills, contribute and when dependencies move in unexpected ways, it creates lots of waves. It’s better to be explicit in such situations and do exactly what the user is requesting.
Actually, what would be the difference between:
poetry lock --update
: generate the lock file, updating the dependenciespoetry update
: update the dependencies, generating the lock fileNo one of the two will change the content of
pyproject.toml
, and then they both generate a lock file compliant with it.To me, the two commands are doing the same operation, but maybe I’m just not able to spot the difference.
If this is actually true, it would be confusing to have two different commands performing the exact same operation, so I’d rather propose to make
poetry lock
always behaving in the--no-update
mode, and nothing else. To update, there is a dedicated command.