Replies: 1 comment
-
After playing around with Bundler and Cargo, now I'm not so sure about my question. Here's the repoduce for poetry beyond the git use case above.
Doing the same with Additionally, Cargo equally doesn't know. If you delete a crate off of disk and then So, I don't know what behavior I'm expecting but all these dependency managers have different nuances and they aren't as similar as I thought. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Let's say someone started and merged a branch since I last git pulled main. Let's say that the dependencies changed and I'm not aware.
Last time I ran
poetry run ...
I had installedrequests 2.26.0
butmain
has been changed so that we are supposed to be using2.31.0
. Main or HEAD basically has2.31.0
as an exact pinned dependency butpoetry check
seems to just check that the lock file and the pyproject.toml file are in sync.poetry run pip list
shows what is installed basically off the old branch.So if I checkout
1234
and I'm a different team member, I never ranpoetry install
. So I have 2.26.0.Of course, if I run
poetry install
now I'm in sync. But I didn't know that. I could have run tests with the wrong package.If
2.31.0
is required then something shouldn't something error out to make repeatable builds happen? I'd expectpoetry run
to say "you need to run poetry install". Orpip list
to be accurate in terms of git. So, I have to remember to runpoetry install
when switching branches. In other package managers, this might happen automatically (cargo) or I will get an error (bundler), even telling me what to do next.I personally do not use git hooks for any reason btw ...
Beta Was this translation helpful? Give feedback.
All reactions