Solve the error error fetching remote repo origin problem in Git on Jenkins

The following error popped up in the Jenkins compilation today

 > git fetch --tags --progress https://github.com/XXX.git +refs/heads/*:refs/remotes/origin/*
ERROR: Error fetching remote repo 'origin'

But then there are some logs

stdout: 
stderr: From https://github.com/XXX
 ! [rejected]          snap/master/20191024_1946 -> snap/master/20191024_1946  (would clobber existing tag)

To prevent any last minute code>Error remote repo ‘origin’ after last minute promotion, all methods were tried and failed.

    gilis-remote-t view remote tagsgit tag-l view local taggtag-d XXX ## delete local taggit fetch origin –prune tags ## finally pull remote tags

Problem solving

Read More: