error "fatal: refs/remotes/origin/stable^0: not a valid SHA1" with repo init command

Viewed 1938

I have an issue with my ci while running the following repo init (with both manifest and repo url):

repo init --no-clone-bundle -u <manifest url> -b <branch name> --repo-url <repo url> --no-repo-verify

The repo initialization process is starting, but it won't finish due to an error which terminates the initialization:

fatal: refs/remotes/origin/stable^0: not a valid SHA1

I ran with few branches in the same repo and it would not work, but the thing is when I'm trying a different repo - the error won't come up. So I'm assuming it's repo-level error and the main question is what is this "stable^0" and I'm struggling with how to do it right.

Any suggestions?

2 Answers

This kind of issue happens when, for some reason, the refs have been changed on the remote side - due to a rebase or removing a tag, branch, etc.

Try to look for those references in your manifest and compare it with those on remote server - check if the references still apply and update your manifest with the correct references.

Remove --repo-url and allow the repo tool to decide the repo source

Related