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

Fails to resolve git packed-refs #343

Closed
KevinCathcart opened this issue Jul 16, 2019 · 1 comment · Fixed by #344 or dotnet/arcade#3302
Closed

Fails to resolve git packed-refs #343

KevinCathcart opened this issue Jul 16, 2019 · 1 comment · Fixed by #344 or dotnet/arcade#3302
Labels
bug Something isn't working

Comments

@KevinCathcart
Copy link

When the codebase was changed to use direct Git file reading, instead of libgitsharp, a regression was introduced.

The regression is that when resolving refs, the new code fails to take into account existence of the packed-refs file. Therefore, if HEAD points to a packed ref, sourcelink will not be able to find the commit hash, and will fail with the message "Repository has no commit."

This especially impacts TeamCity, since it appears to be writing the packed-refs file directly, instead using the normal git fetch workflow, which means that unlike most build scenarios, HEAD will be pointing to a packed ref, rather than a loose one.

@tmat
Copy link
Member

tmat commented Jul 16, 2019

Thanks for pointing this out.

https://git-scm.com/docs/git-pack-refs for reference.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants