Try finding commit using short SHA if it is not on HEAD#9748
Try finding commit using short SHA if it is not on HEAD#9748radoering merged 9 commits intopython-poetry:mainfrom
Conversation
|
It seemed to work in my case, but I would appreciate it if someone looked into this and told me if it makes sense. I can see some integration tests against https://github.com/python-poetry/test-fixture-vcs-repository but every commit there seems to have its own head/tag which does not allow to reproduce the initial issue... |
5db267b to
a5b0b85
Compare
|
@jelmer I'd appreciate if you could take a look if it makes sense (from a dulwich point of view). |
We have tests in tests/integration/test_utils_vcs_git.py and in main/tests/vcs/git/test_backend.py. Fast tests that do not require an external repository can be put into the latter.
I have no idea if it is feasible, but maybe we can create a local repository in the test? |
|
Creating a local repository in e.g. a tempdir should be fast and easy with Dulwich - Repo.init(path) will do what you need. |
ea12ea5 to
0d88b37
Compare
|
I added the test, I had to introduce a new marker "skip_git_mock" not to mock "git clone" as that one is not ready to mock local clone. The rest was copied from |
LGTM, for what it's worth. |
|
This will likely also require #9849 if we intend to update dulwich. |
Since recent dulwich releases are bumping only the patch number, poetry users are already getting the latest dulwich. Are you saying that dulwich has released a breaking change in a patch release? Edit the poetry 1.8 branch is still on the dulwich 0.21 series, so I am wrong about poetry users already getting the latest. Nevertheless #9849 says it was fixing something from "dulwich >=0.22.2" so the question stands |
|
I'm curious what change is, we haven't had reports of API breakages. |
dd3174e to
c45e593
Compare
|
@jelmer To close the loop regarding @dimbleby 's question; I have raised a dulwich issue for triage with a reproducer. Cross-post: jelmer/dulwich#1443 |
82e470a to
18c719f
Compare
|
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Pull Request Check List
If a dependency specifies a git revision using a short hash, Dulwich does not provide an option to directly address it (see discussion in #9560); however, we can still list revisions and find what we are looking for.
Resolves: #9560 #6455