-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
poetry update
doesn't update git dependencies that specify branch but not revision
#10025
Comments
poetry already behaves exactly as you ask if you think otherwise please provide a way to reproduce |
Well, I've been running |
Which version of Poetry are you using? |
Poetry 1.8.5. Python 3.13.1. On MacOS 13.7.1 (Intel) if it matters. Fwiw, I ended up deleting the |
They are not. Suggest provide eg a docker image or an example repository. And of course you should use the latest release, if it turns out this is something that is recently fixed then none of us should want to spend time on that. |
Until now I wasn't able to reproduce this. So there is a good chance it's a problem on your end. Make sure new commits are really pushed to the remote branch. |
The workaround suggested in #6046 (comment)_ is to run
poetry update
. But if you've specified a branch for your git repo,poetry update <dependency_name>
doesn't update theresolved_reference
commit specification.So imagine a pyproject.toml with the following:
And say the
HEAD
of themain
branch is commitabcd1234...
. Afterpoetry install
, poetry.lock will contain something like:Now I make another commit on
main
and push to github. Now theHEAD
of themain
branch is commit9876fedc...
The expected behavior is that
poetry update my_dep
will update poetry.lock to look like this:The actual behavior is that poetry.lock is unchanged, still containing:
Obviously we don't want
poetry install
to entirely ignore theresolved_reference
, which is the bug fixed in #2921, to my understanding. But it should still be possible to update the locked commit inresolved_reference
when explicitly requested.The text was updated successfully, but these errors were encountered: