Skip to content
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

Fix an error that occurred when using conan.tools.scm.Git.fetch_commit() in a subfolder #17369

Merged

Conversation

bkarasm
Copy link
Contributor

@bkarasm bkarasm commented Nov 24, 2024

Changelog: Fix: Fixed an error that occurred when using conan.tools.scm.Git.fetch_commit() in a subfolder.
Docs: Omit

Fixes #17295

@CLAassistant
Copy link

CLAassistant commented Nov 24, 2024

CLA assistant check
All committers have signed the CLA.

@memsharded memsharded self-assigned this Nov 24, 2024
Copy link
Member

@memsharded memsharded left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks very much @bkarasm

@memsharded memsharded added this to the 2.10.0 milestone Nov 24, 2024
@memsharded
Copy link
Member

Please don't forget to sign the CLA above (or if you signed, sometimes when not using the same email as the Github one, Github doesn't recognize the signature), so we can merge it for next release. Thanks again for your contribution!

@memsharded
Copy link
Member

Seems tests are broken in Linux only (work in Windows and Mac):

TestGitShallowClone.test_clone_to_subfolder

onan.errors.ConanException: Command 'git fetch --depth 1 origin 52bdb239b6917d3fb2d01849c78e07985f1722b3' failed with errorcode '1'

E           b'error: Server does not allow request for unadvertised object 52bdb239b6917d3fb2d01849c78e07985f1722b3\n'

@bkarasm
Copy link
Contributor Author

bkarasm commented Nov 25, 2024

@memsharded I'll take a look at the failing tests later today. Regarding the CLA I already signed it using the same account that I contributed with. Not sure why it still shows it is pending.

@bkarasm
Copy link
Contributor Author

bkarasm commented Nov 25, 2024

A different test that verifies git.fetch_commit() has this pytest marker: @pytest.mark.skipif(platform.system() == "Linux", reason="Git version in Linux not support it"). I added similar marker for the failing test.

@memsharded
Copy link
Member

Thanks for following up!

The CI is now green, ready to be merged.
Still the CLA says it has not been approved. I have checked the git log output, and I'd say it is possible that the commits are signed with other email different the one you are using for your Github account, could you please double check?

@bkarasm bkarasm force-pushed the fix/git-fetch-commit-create-subfolder branch from fdb4353 to bcee7f7 Compare November 25, 2024 22:32
@bkarasm
Copy link
Contributor Author

bkarasm commented Nov 25, 2024

Thanks @memsharded . Indeed that was the case. It should be fixed now.

@memsharded memsharded merged commit 6bdd529 into conan-io:develop2 Nov 25, 2024
2 checks passed
@memsharded
Copy link
Member

Merged, it will be in next Conan 2.10. Thanks very much for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[bug] git.fetch_commit() throws an error when downloading sources to subfolder
4 participants