Reputation: 31
I am running Jenkins on windows and when I am trying to build my project through jenkins, the following error occurs:
git.exe -c core.askpass=true fetch --tags --progress <url>Assist-Ops.git +refs/heads/*:refs/remotes/origin/*
ERROR: Timeout after 10 minutes
> git.exe config --local --remove-section credential # timeout=10
ERROR: Error fetching remote repo 'origin'
hudson.plugins.git.GitException: Failed to fetch from <url>
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:810)
at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1066)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1097)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1269)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:607)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:529)
at hudson.model.Run.execute(Run.java:1738)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:410)
Caused by: hudson.plugins.git.GitException: Command "git.exe -c core.askpass=true fetch --tags --progress <URL>/Assist-Ops.git +refs/heads/*:refs/remotes/origin/*" returned status code -1:
stdout:
stderr:
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1719)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1463)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:63)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:314)
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:808)
Started getting this error after I changed my password.
I have created new SSH key and added it to github repository. I am able to clone the repository and build though command line.
mvn clean install
Upvotes: 3
Views: 25291
Reputation: 1658
For me this error was coming because I was using a string parameter path in my pipeline.
Renaming path to something else fixed it.
Upvotes: 1
Reputation: 4050
try to disable use of the git credential cache using git config --global --unset credential.helper
. You may also need to do git config --system --unset credential.helper
if this has been set in the system config file
Upvotes: 2
Reputation: 38639
If you read the documentation, you will find that core.askpass
is not a boolean value but an external program that is used to ask you for a password. So setting this variable to true
is not the right thing to do.
Upvotes: 0