Hi! I am using Jenkins LTS 2.190.2 via Docker container and I'm experiencing this issue using a SCM declarative pipeline. I have an Extensible Choice param in the job that is letting me pick a branch, and then I am referring to the branch variable selection as
in the pipeline settings for the Jenkinsfile in SCM (specifically GIT). Based on my reading of this issue, it seems as if folks think this is fixed? I am definitely able to repo consistently across a number of declarative pipeline jobs on my server. I have config extremely similar to Yan Wang's screenshots from 2016. Boguslaw Klimas Any insight here?
Screenshots:
choice settings
pipeline settings
Error from build:
hudson.plugins.git.GitException: Command "git fetch --tags --progress --prune -- origin +refs/heads/${webapp_branch}:refs/remotes/origin/${webapp_branch}" returned status code 128:
stdout:
stderr: fatal: Couldn't find remote ref refs/heads/${webapp_branch} at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2174)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1866)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$500(CliGitAPIImpl.java:78)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:547)
at jenkins.plugins.git.GitSCMFileSystem$BuilderImpl.build(GitSCMFileSystem.java:358)
at jenkins.scm.api.SCMFileSystem.of(SCMFileSystem.java:197)
at jenkins.scm.api.SCMFileSystem.of(SCMFileSystem.java:173)
at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:113)
at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:67)
at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:299)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:429)
Finished: FAILURE
Oh, I just tried String Parameters and it does not work neither.
So I guess the problem is not with Git Parameter plugin but SCM plugin.
Related issue is: https://issues.jenkins-ci.org/browse/JENKINS-34540