Hi all. We’re running into an issue with an issue scanning the main repo that’s used for several different pipeline jobs. Right now whenever a job scans this repo to look for branches to build, I get the following error at the end of the scanning log:
> git.exe fetch --tags --force --progress --prune -- origin +refs/heads/*:refs/remotes/origin/* # timeout=10
ERROR: [Mon Oct 23 14:28:56 PDT 2023] Could not fetch branches from source 28812075-85b0-489f-954e-ce1d47119ee0
[Mon Oct 23 14:28:56 PDT 2023] Finished branch indexing. Indexing took 4.3 sec
FATAL: Failed to recompute children of <redacted>
hudson.plugins.git.GitException: Command "git.exe fetch --tags --force --progress --prune -- origin +refs/heads/*:refs/remotes/origin/*" returned status code 128:
stdout:
stderr: fatal: unterminated line in .git/packed-refs:
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2842)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:2185)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:635)
at jenkins.plugins.git.AbstractGitSCMSource$8.run(AbstractGitSCMSource.java:605)
at jenkins.plugins.git.AbstractGitSCMSource$8.run(AbstractGitSCMSource.java:591)
at jenkins.plugins.git.AbstractGitSCMSource.doRetrieve(AbstractGitSCMSource.java:397)
at jenkins.plugins.git.AbstractGitSCMSource.doRetrieve(AbstractGitSCMSource.java:351)
at jenkins.plugins.git.AbstractGitSCMSource.retrieve(AbstractGitSCMSource.java:591)
at jenkins.scm.api.SCMSource._retrieve(SCMSource.java:372)
at jenkins.scm.api.SCMSource.fetch(SCMSource.java:282)
at jenkins.branch.MultiBranchProject.computeChildren(MultiBranchProject.java:654)
at com.cloudbees.hudson.plugins.folder.computed.ComputedFolder.updateChildren(ComputedFolder.java:269)
at com.cloudbees.hudson.plugins.folder.computed.FolderComputation.run(FolderComputation.java:167)
at jenkins.branch.MultiBranchProject$BranchIndexing.run(MultiBranchProject.java:1057)
at hudson.model.ResourceController.execute(ResourceController.java:101)
at hudson.model.Executor.run(Executor.java:442)
Finished: FAILURE
Looking at this error online, the consensus seems to be to just delete the .git/packed-refs file. The problem is I don’t know where that file is in this case, since its not even gotten to the part where its building anything yet. I’ve not been able to find it in the Jenkins server. And since files in .git aren’t tracked (and don’t look like they can be from what I’ve tried), I can’t update the repo to have this file deleted.
Any ideas?