"fatal: reference is not a tree: …" when building tags/commits that are not part of a followed branch
When a runner has previously built a repository and gets assigned another build for the same repo, it seems to fetch changes without the --tags
flag.
This causes tags and commits that are not part of a branch to be skipped during fetch and the subsequent checkout fails with fatal: reference is not a tree: <commit>
.