'VSTS Git Fetch Failed with exit code: 128

It looks like a duplicate of this question but my issue is that I am running a hosted version. VSTS GIT Fetch Failed

I enabled system debug and pretty much allowed all roles all access since its only me at the moment. I had created a new project recently and that is the only thing that has changed for me in VSTS. I am running on a hosted agent and tried creating a new build pipeline. Has anyone faced this recently?

enter image description here



Solution 1:[1]

Another possible cause of the "Git fetch failed with exit code: 128" error message - it happened to us for pull requests builds when a developer clicked merge right after a pull request was created and the build, of course, hasn't finished yet.

So it was the "follow the process" solution for us. It could be enforced also.

Solution 2:[2]

For anyone who finds this question, while searching for the 128 exit code:

In my case it was Bitbucket Server running out of space (full hard drive) which caused this error. If you're hosting your git server yourself, check your hard drive:

df

Maybe that helps someone.

Solution 3:[3]

I recently came across this issue and after several tries what worked for me is a check box for "Checkout Files from LFS" while adding the artifacts to Azure release/pipeline. Here

enter image description here

Solution 4:[4]

In my case, I'm traing check out branche from different project, other than where I was creating the pipeline and there were no permissions.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 mivra
Solution 2 Pampy
Solution 3 Ankit Kotnala
Solution 4 Jan Mucha