Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-67900

ERROR: Error fetching remote repo 'origin' when creating a new pipeline with changes to the parameters values if one parameter is PATH

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None

      When creating a new build using the same Jenkins pipeline with changes to values of some parameters that are not related to the repository parameters. the job failed with below

      Started by user email
       Running as email
       Resume disabled by user, switching to high-performance, low-durability mode.
       Running on Jenkins in /var/lib/jenkins/workspace/Job
       Installer "Run Shell Command" cannot be used to install "node" on the node "Jenkins"
       Installer "Run Shell Command" cannot be used to install "node" on the node "Jenkins"
       Running in /var/lib/jenkins/workspace/Job/test
       [Default] $ sh -e /var/lib/jenkins/tools/hudson.plugins.git.GitTool/Default/hudson5882823506668773524.sh
       /bin/git
       [Default] $ sh -e /var/lib/jenkins/tools/hudson.plugins.git.GitTool/Default/hudson11309819648014258385.sh
       /bin/git
       The recommended git tool is: NONE
       using credential Jenkins_BitBucket_Credentails
       > /usr/bin/git rev-parse --resolve-git-dir /var/lib/jenkins/workspace/Job/test/.git # timeout=10
       Fetching changes from the remote Git repository
       > /usr/bin/git config remote.origin.url Repository_URL # timeout=10
       Fetching upstream changes from Repository_URL
       > /usr/bin/git --version # timeout=10
       > git --version # 'git version 2.32.0'
       using GIT_ASKPASS to set credentials Jenkins BitBucket Credentails
       > /usr/bin/git fetch --tags --force --progress – Repository_URL +refs/heads/*:refs/remotes/origin/* # timeout=10
       ERROR: Error fetching remote repo 'origin'
       hudson.plugins.git.GitException: Failed to fetch from Repository_URL
       at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:1001)
       at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1242)
       at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1302)
       at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:129)
       at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:97)
       at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:84)
       at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
       at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
       at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
       at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
       at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
       at java.base/java.lang.Thread.run(Thread.java:829)
       Caused by: hudson.plugins.git.GitException: Command "/usr/bin/git fetch --tags --force --progress – Repository_URL +refs/heads/*:refs/remotes/origin/*" returned status code 128:
       stdout:
       stderr: /var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh: line 4: cat: command not found
       error: unable to read askpass response from '/var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh'
       fatal: could not read Password for 'https://User@bitbucket.org': terminal prompts disabled
      
      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2671)
       at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:2096)
       at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$500(CliGitAPIImpl.java:84)
       at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:618)
       at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:999)
       ... 11 more
       Stage "Build" skipped due to earlier failure(s)
       Stage "Deploy" skipped due to earlier failure(s)
       Stage "CDN Invalidation" skipped due to earlier failure(s)
       I will always say Hello again!
       Slack Send Pipeline step running, values are - baseUrl: <empty>, teamDomain: domainName, channel: U0261CCPEQG, color: danger, botUser: false, tokenCredentialId: Jenkins_Slack_Credentials, notifyCommitters: false, iconEmoji: <empty>, username: <empty>, timestamp: <empty>
       ERROR: Error fetching remote repo 'origin'
       Finished: FAILURE
      

      Jenkins Pipeline 

      // def AWS_ROLE = ''
       // def getBuildUser()
      
      { // return currentBuild.rawBuild.getCause(Cause.UserIdCause).getUserId() // }
      
      def COLOR_MAP = [
       'SUCCESS': 'good',
       'FAILURE': 'danger',
       ]
       pipeline {
       environment
      
      { BUILD_USER = '' }
      
      agent \{ label 'Jenkins' }
       stages {
       stage('Setup parameters')
      
      { tools \\{nodejs "node"}
      
      steps {
       script { 
        properties([ 
          parameters([ 
            string( defaultValue: 'master', description: 'Specify the Brnach Name', name: 'BRANCH_NAME', trim: true ),
            string( defaultValue: 'slackId', description: 'Specify the Slack Channel ID or User slack ID', name: 'SLACK_CHANNEL', trim: true ),
            [$class: 'WHideParameterDefinition', defaultValue: 'ValuesChanged', description: 'Specify the Bucket Name', name: 'BUCKET'],
            [$class: 'WHideParameterDefinition', defaultValue: 'ROLE', description: 'Specify the RoleName', name: 'ROLE'],
            [$class: 'WHideParameterDefinition', defaultValue: 'REPOSITORY', description: 'Specify the REPOSITORY Name', name: 'REPOSITORY'],
            [$class: 'WHideParameterDefinition', defaultValue: 'http-api', description: 'Specify the path', name: 'PATH'],
            [$class: 'WHideParameterDefinition', defaultValue: 'Region', description: 'Specify the Region', name: 'Region'],
            [$class: 'WHideParameterDefinition', defaultValue: 'xxxxxxxxxx', description: 'Specify the Distribution Id', name: 'someDistributionId'],
            [$class: 'WHideParameterDefinition', defaultValue: 'xxxxxxxxxx', description: 'Specify the Account number', name: 'Account'],
            [$class: 'WHideParameterDefinition', defaultValue: 'xxxxxxxxxx', description: 'Specify The REACT_APP_GOOGLE_CLIENT_ID', name: 'REACT_APP_GOOGLE_CLIENT_ID'] 
            ]) 
          ]) 
        }
      }
       stage('Code Checkout'){
       steps {
       dir('test')
      
      { git branch: params.BRANCH_NAME, credentialsId: 'JenkinsBitBucketCredentails', url: params.REPOSITORY }
      
      }
       }
       stage('Build')
      
      { agent \\{ label 'worker' }
       tools \{nodejs "node"}
       steps {
       dir('test') \{ git branch: params.BRANCH_NAME, credentialsId: 'JenkinsBitBucketCredentails', url: params.REPOSITORY }
       dir('test') \{ sh 'npm install --prefer-offline --no-audit --progress=false' sh 'npm run test' sh 'npm run build-dev' }
       }
       }
       stage('Deploy') \{ agent { label 'worker' }
      
      steps {
       dir('test/build') {
       withAWS(credentials: 'JenkinsAWSCredentails', region: params.Region, role: params.ROLE, roleAccount: params.Account)
      
      { s3Upload acl: 'Private', bucket: params.BUCKET, cacheControl: '', excludePathPattern: '', includePathPattern: '**', metadatas: [''], redirectLocation: '', sseAlgorithm: '', tags: '', workingDir: '', path : params.PATH }
      
      }
       }
       }
       stage('CDN Invalidation') {
       steps {
       withAWS(credentials: 'JenkinsAWSCredentails', region: params.Region, role: params.ROLE, roleAccount: params.Account)
      
      { cfInvalidate(distribution: params.someDistributionId, paths:['/*'], waitForCompletion: true) }
      
      }
       }
       }
       post {
       always
      
      { echo 'I will always say Hello again!' }
      
      success {
       slackSend channel: params.SLACK_CHANNEL, color: COLOR_MAP[currentBuild.currentResult], message: "Build ${currentBuild.currentResult}: ${env.JOB_NAME} #${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}"
       }
       failure {
       slackSend channel: params.SLACK_CHANNEL, color: COLOR_MAP[currentBuild.currentResult], message: "Build ${currentBuild.currentResult}: ${env.JOB_NAME} #${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}"
       }
       }
       }
      

      logs for jenkins 

       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       java.lang.SecurityException: class "Log4jHotPatch"'s signer information does not match signer information of other classes in the same package
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.checkCerts(ClassLoader.java:1151)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.preDefineClass(ClassLoader.java:906)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1015)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:174)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:800)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:698)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:621)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:579)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.instrument/sun.instrument.InstrumentationImpl.loadClassAndStartAgent(InstrumentationImpl.java:431)
       Feb 28, 2022 7:19:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.instrument/sun.instrument.InstrumentationImpl.loadClassAndCallAgentmain(InstrumentationImpl.java:535)
       Feb 28, 2022 7:19:53 AM WARNING com.cloudbees.jenkins.plugins.BitbucketJobProbe triggerMatchingJobs
       No SCM configuration was found!
       Feb 28, 2022 7:20:37 AM WARNING com.cloudbees.jenkins.plugins.BitbucketJobProbe triggerMatchingJobs
       No SCM configuration was found!
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       java.lang.SecurityException: class "Log4jHotPatch"'s signer information does not match signer information of other classes in the same package
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.checkCerts(ClassLoader.java:1151)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.preDefineClass(ClassLoader.java:906)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1015)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:174)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.defineClass(BuiltinClassLoader.java:800)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.findClassOnClassPathOrNull(BuiltinClassLoader.java:698)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.loadClassOrNull(BuiltinClassLoader.java:621)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:579)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.instrument/sun.instrument.InstrumentationImpl.loadClassAndStartAgent(InstrumentationImpl.java:431)
       Feb 28, 2022 7:22:02 AM SEVERE io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils$1 print
       at java.instrument/sun.instrument.InstrumentationImpl.loadClassAndCallAgentmain(InstrumentationImpl.java:535)
       Feb 28, 2022 7:22:25 AM INFO hudson.model.AsyncPeriodicWork lambda$doRun$1
       Started Periodic background build discarder
       Feb 28, 2022 7:22:25 AM INFO hudson.model.AsyncPeriodicWork lambda$doRun$1
       Finished Periodic background build discarder. 4 ms
       Feb 28, 2022 7:24:09 AM INFO hudson.model.AsyncPeriodicWork lambda$doRun$1
       Started EC2 alive agents monitor
       Feb 28, 2022 7:24:09 AM INFO hudson.model.AsyncPeriodicWork lambda$doRun$1
       Finished EC2 alive agents monitor. 0 ms
      

      in Jenkins 2.319.3

          [JENKINS-67900] ERROR: Error fetching remote repo 'origin' when creating a new pipeline with changes to the parameters values if one parameter is PATH

          What are the Java version and the Log4jHotPatch version?

          Kalle Niemitalo added a comment - What are the Java version and the Log4jHotPatch version?

          "Loading Java Agent " would get logged to stderr in each JVM process used by Jenkins, I think.

          Kalle Niemitalo added a comment - "Loading Java Agent " would get logged to stderr in each JVM process used by Jenkins, I think.

          pom.xml uses maven-gpg-plugin to sign the artifacts of hotpatch-for-apache-log4j2. If class Log4jHotPatch is signed in this way but classes in Jenkins plugins are not signed at all (and especially not by the same signer) then maybe that causes the SecurityException.

          The errors are logged by the PrintStream created by BitBucketPPRUtils.createLoggingProxyForErrors. Static initialization blocks in BitBucketPPRJobProbe, BitBucketPPRTrigger, and BitBucketPPREnvironmentContributor set that PrintStream as the System.err stream. That looks rather hacky to me.

          I suggest you uninstall the Bitbucket Push and Pull Request plugin and test whether the error still occurs. If it does, then there should be details in the stderr log, as the plugin won't be redirecting the stderr text to Jenkins logs and misleadingly labeling it as io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils.

          Kalle Niemitalo added a comment - pom.xml uses maven-gpg-plugin to sign the artifacts of hotpatch-for-apache-log4j2. If class Log4jHotPatch is signed in this way but classes in Jenkins plugins are not signed at all (and especially not by the same signer) then maybe that causes the SecurityException. The errors are logged by the PrintStream created by BitBucketPPRUtils.createLoggingProxyForErrors . Static initialization blocks in BitBucketPPRJobProbe , BitBucketPPRTrigger , and BitBucketPPREnvironmentContributor set that PrintStream as the System.err stream. That looks rather hacky to me. I suggest you uninstall the Bitbucket Push and Pull Request plugin and test whether the error still occurs. If it does, then there should be details in the stderr log, as the plugin won't be redirecting the stderr text to Jenkins logs and misleadingly labeling it as io.jenkins.plugins.bitbucketpushandpullrequest.common.BitBucketPPRUtils.

          It is also possible that the Log4jHotPatch error in the log has nothing to do with the reason why the build fails.

          Kalle Niemitalo added a comment - It is also possible that the Log4jHotPatch error in the log has nothing to do with the reason why the build fails.

          faroug Abdalaziz added a comment - - edited

          Sorry to be precise, The same build is working fine using (POLL SCM), this is only happened in new or cloned build with the same pipeline, not sure if the same build will not be triggered if I changed the value.
          for the following

          • Java Version is
            openjdk 11.0.13 2021-10-19 LTS
            OpenJDK Runtime Environment 18.9 (build 11.0.13+8-LTS)
            OpenJDK 64-Bit Server VM 18.9 (build 11.0.13+8-LTS, mixed mode, sharing)
            
          • based on following article https://www.jenkins.io/blog/2021/12/10/log4j2-rce-CVE-2021-44228/ and running the code mentioned there to determine if I'm using it or not the result is as Script1
            this is the actual result when running the
            Result
          groovy.lang.MissingPropertyException: No such property: org for class: Script1
          	at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:53)
          	at org.codehaus.groovy.runtime.callsite.PogoGetPropertySite.getProperty(PogoGetPropertySite.java:52)
          	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGroovyObjectGetProperty(AbstractCallSite.java:307)
          	at Script1.run(Script1.groovy:1)
          	at groovy.lang.GroovyShell.evaluate(GroovyShell.java:585)
          	at groovy.lang.GroovyShell.evaluate(GroovyShell.java:623)
          	at groovy.lang.GroovyShell.evaluate(GroovyShell.java:594)
          	at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:143)
          	at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:113)
          	at hudson.remoting.LocalChannel.call(LocalChannel.java:46)
          	at hudson.util.RemotingDiagnostics.executeGroovy(RemotingDiagnostics.java:110)
          	at jenkins.model.Jenkins._doScript(Jenkins.java:4698)
          	at jenkins.model.Jenkins.doScript(Jenkins.java:4669)
          	at java.base/java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:710)
          	at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:393)
          	at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:405)
          	at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:208)
          	at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:141)
          	at org.kohsuke.stapler.MetaClass$11.doDispatch(MetaClass.java:536)
          	at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58)
          	at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:766)
          	at org.kohsuke.stapler.Stapler.invoke(Stapler.java:898)
          	at org.kohsuke.stapler.Stapler.invoke(Stapler.java:694)
          	at org.kohsuke.stapler.Stapler.service(Stapler.java:240)
          	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
          	at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:799)
          	at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1626)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:156)
          	at org.jenkinsci.plugins.ssegateway.Endpoint$SSEListenChannelFilter.doFilter(Endpoint.java:248)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153)
          	at jenkins.telemetry.impl.UserLanguages$AcceptLanguageFilter.doFilter(UserLanguages.java:128)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153)
          	at jenkins.security.ResourceDomainFilter.doFilter(ResourceDomainFilter.java:80)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153)
          	at io.jenkins.blueocean.ResourceCacheControl.doFilter(ResourceCacheControl.java:134)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153)
          	at io.jenkins.blueocean.auth.jwt.impl.JwtAuthenticationFilter.doFilter(JwtAuthenticationFilter.java:60)
          	at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153)
          	at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:159)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:153)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:92)
          	at jenkins.security.AcegiSecurityExceptionFilter.doFilter(AcegiSecurityExceptionFilter.java:52)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at hudson.security.UnwrapSecurityExceptionFilter.doFilter(UnwrapSecurityExceptionFilter.java:53)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:121)
          	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:115)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:105)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:101)
          	at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:92)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:218)
          	at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:212)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at jenkins.security.BasicHeaderProcessor.doFilter(BasicHeaderProcessor.java:97)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:110)
          	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:80)
          	at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:62)
          	at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97)
          	at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:109)
          	at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:171)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:51)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:85)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at org.kohsuke.stapler.DiagnosticThreadNameFilter.doFilter(DiagnosticThreadNameFilter.java:30)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at jenkins.security.SuspiciousRequestFilter.doFilter(SuspiciousRequestFilter.java:39)
          	at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193)
          	at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
          	at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:548)
          	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
          	at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:578)
          	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
          	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
          	at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1624)
          	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
          	at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1434)
          	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
          	at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:501)
          	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1594)
          	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
          	at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1349)
          	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
          	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
          	at org.eclipse.jetty.server.Server.handle(Server.java:516)
          	at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:388)
          	at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:633)
          	at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:380)
          	at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
          	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
          	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
          	at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
          	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)
          	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)
          	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)
          	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)
          	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:386)
          	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
          	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
          	at java.base/java.lang.Thread.run(Thread.java:829)
          

          Thanks for you help I'll reinstall the Bitbucket Push and Pull Request Plugin and update the ticket based on that

          faroug Abdalaziz added a comment - - edited Sorry to be precise, The same build is working fine using (POLL SCM), this is only happened in new or cloned build with the same pipeline, not sure if the same build will not be triggered if I changed the value. for the following Java Version is openjdk 11.0.13 2021-10-19 LTS OpenJDK Runtime Environment 18.9 (build 11.0.13+8-LTS) OpenJDK 64-Bit Server VM 18.9 (build 11.0.13+8-LTS, mixed mode, sharing) based on following article https://www.jenkins.io/blog/2021/12/10/log4j2-rce-CVE-2021-44228/ and running the code mentioned there to determine if I'm using it or not the result is as Script1 this is the actual result when running the Result groovy.lang.MissingPropertyException: No such property: org for class: Script1 at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:53) at org.codehaus.groovy.runtime.callsite.PogoGetPropertySite.getProperty(PogoGetPropertySite.java:52) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGroovyObjectGetProperty(AbstractCallSite.java:307) at Script1.run(Script1.groovy:1) at groovy.lang.GroovyShell.evaluate(GroovyShell.java:585) at groovy.lang.GroovyShell.evaluate(GroovyShell.java:623) at groovy.lang.GroovyShell.evaluate(GroovyShell.java:594) at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:143) at hudson.util.RemotingDiagnostics$Script.call(RemotingDiagnostics.java:113) at hudson.remoting.LocalChannel.call(LocalChannel.java:46) at hudson.util.RemotingDiagnostics.executeGroovy(RemotingDiagnostics.java:110) at jenkins.model.Jenkins._doScript(Jenkins.java:4698) at jenkins.model.Jenkins.doScript(Jenkins.java:4669) at java.base/java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:710) at org.kohsuke.stapler.Function$MethodFunction.invoke(Function.java:393) at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:405) at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:208) at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:141) at org.kohsuke.stapler.MetaClass$11.doDispatch(MetaClass.java:536) at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:58) at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:766) at org.kohsuke.stapler.Stapler.invoke(Stapler.java:898) at org.kohsuke.stapler.Stapler.invoke(Stapler.java:694) at org.kohsuke.stapler.Stapler.service(Stapler.java:240) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:799) at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1626) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:156) at org.jenkinsci.plugins.ssegateway.Endpoint$SSEListenChannelFilter.doFilter(Endpoint.java:248) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153) at jenkins.telemetry.impl.UserLanguages$AcceptLanguageFilter.doFilter(UserLanguages.java:128) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153) at jenkins.security.ResourceDomainFilter.doFilter(ResourceDomainFilter.java:80) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153) at io.jenkins.blueocean.ResourceCacheControl.doFilter(ResourceCacheControl.java:134) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153) at io.jenkins.blueocean.auth.jwt.impl.JwtAuthenticationFilter.doFilter(JwtAuthenticationFilter.java:60) at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:153) at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:159) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:153) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:92) at jenkins.security.AcegiSecurityExceptionFilter.doFilter(AcegiSecurityExceptionFilter.java:52) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at hudson.security.UnwrapSecurityExceptionFilter.doFilter(UnwrapSecurityExceptionFilter.java:53) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:121) at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:115) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:105) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:101) at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:92) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:218) at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:212) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at jenkins.security.BasicHeaderProcessor.doFilter(BasicHeaderProcessor.java:97) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:110) at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:80) at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:62) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:97) at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:109) at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:171) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:51) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:85) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at org.kohsuke.stapler.DiagnosticThreadNameFilter.doFilter(DiagnosticThreadNameFilter.java:30) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at jenkins.security.SuspiciousRequestFilter.doFilter(SuspiciousRequestFilter.java:39) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:548) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:578) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235) at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1624) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1434) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:501) at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1594) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1349) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) at org.eclipse.jetty.server.Server.handle(Server.java:516) at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:388) at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:633) at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:380) at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277) at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131) at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:386) at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883) at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034) at java.base/java.lang. Thread .run( Thread .java:829) Thanks for you help I'll reinstall the Bitbucket Push and Pull Request Plugin and update the ticket based on that

          Yes I think it's nothing to do with the Log4jHotPatch, however not sure why I do have that in the logs
          For the Bitbucket Push & Pull I've completely removed it. as it's not even related to the build. tried to remove all the bitbucket plugins that are not required for the job. however couldn't uninstall Bitbucket Branch Source Plugin. I also downgrade the git, which result in the following error which acceptable as different syntax

          WorkflowScript: 44: Invalid parameter "credentialsId", did you mean "properties"? @ line 44, column 52.
                git branch: params.BRANCH, credential
                                           ^
          
          WorkflowScript: 44: Invalid parameter "url", did you mean "name"? @ line 44, column 100.
             nkinsBitBucketCredentails', url: 'http
                                           ^
          
          WorkflowScript: 53: Invalid parameter "branch", did you mean "name"? @ line 53, column 29.
                                     git branch: params.BRANCH, credentialsId: 'JenkinsBitBucketCredentails', url: 
          

          But based on what I've noticed is that if I used the pipeline in creating new jobs the first build which without using the parameter plugin, it works fine however all the other builds which will be triggered with Build with Parameters will fail with the ERROR: Error fetching remote repo 'origin'

          faroug Abdalaziz added a comment - Yes I think it's nothing to do with the Log4jHotPatch, however not sure why I do have that in the logs For the Bitbucket Push & Pull I've completely removed it. as it's not even related to the build. tried to remove all the bitbucket plugins that are not required for the job. however couldn't uninstall Bitbucket Branch Source Plugin. I also downgrade the git, which result in the following error which acceptable as different syntax WorkflowScript: 44: Invalid parameter "credentialsId" , did you mean "properties" ? @ line 44, column 52. git branch: params.BRANCH, credential ^ WorkflowScript: 44: Invalid parameter "url" , did you mean "name" ? @ line 44, column 100. nkinsBitBucketCredentails ', url: ' http ^ WorkflowScript: 53: Invalid parameter "branch" , did you mean "name" ? @ line 53, column 29. git branch: params.BRANCH, credentialsId: 'JenkinsBitBucketCredentails' , url: But based on what I've noticed is that if I used the pipeline in creating new jobs the first build which without using the parameter plugin, it works fine however all the other builds which will be triggered with Build with Parameters will fail with the ERROR: Error fetching remote repo 'origin'

          This thing

          Caused by: hudson.plugins.git.GitException: Command "/usr/bin/git fetch --tags --force --progress – Repository_URL +refs/heads/*:refs/remotes/origin/*" returned status code 128:
           stdout:
           stderr: /var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh: line 4: cat: command not found
           error: unable to read askpass response from '/var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh'
           fatal: could not read Password for 'https://User@bitbucket.org': terminal prompts disabled
          

          makes me wonder if there's something changing the PATH environment variable incorrectly. Oh, your pipeline definition contains this:

                [$class: 'WHideParameterDefinition', defaultValue: 'http-api', description: 'Specify the path', name: 'PATH'],
          

          Maybe the PATH parameter conflicts with the PATH environment variable. Can you try renaming the parameter?

          Kalle Niemitalo added a comment - This thing Caused by: hudson.plugins.git.GitException: Command "/usr/bin/git fetch --tags --force --progress – Repository_URL +refs/heads/*:refs/remotes/origin/*" returned status code 128: stdout: stderr: /var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh: line 4: cat: command not found error: unable to read askpass response from '/var/lib/jenkins/workspace/Job/test@tmp/jenkins-gitclient-pass8019568652889463923.sh' fatal: could not read Password for 'https://User@bitbucket.org': terminal prompts disabled makes me wonder if there's something changing the PATH environment variable incorrectly. Oh, your pipeline definition contains this: [$class: 'WHideParameterDefinition' , defaultValue: 'http-api' , description: 'Specify the path' , name: 'PATH' ], Maybe the PATH parameter conflicts with the PATH environment variable. Can you try renaming the parameter?

          Filed JENKINS-67917 about the System.err hijack in Bitbucket Push and Pull Request.

          Kalle Niemitalo added a comment - Filed JENKINS-67917 about the System.err hijack in Bitbucket Push and Pull Request.

          JENKINS-67950 has been filed about the Log4jHotPatch errors in the log.

          Kalle Niemitalo added a comment - JENKINS-67950 has been filed about the Log4jHotPatch errors in the log.

          Kalle Niemitalo added a comment - - edited

          Jenkins calls the ParameterValue.buildEnvironment method (javadoc), to let parameters add themselves to the environment. All the classes that extend ParameterValue and are defined in the Jenkins core do so. This feature is documented in ParametersDefinitionProperty/help.html and https://www.jenkins.io/redirect/parameterized-builds.

          In the Hidden Parameter Plugin, WHideParameterValue extends StringParameterValue and inherits this behavior.

          So, if your pipeline defines a parameter named "PATH" with the default value "http-api", I think it is by design that this sets "PATH=http-api" in the environment and prevents Jenkins from finding the git executable.

          However, the ParametersDefinitionProperty documentation does not look very easy to find for people creating Jenkins pipelines. It might be worth linking to the Parameterized Builds documentation from https://www.jenkins.io/doc/book/pipeline/syntax/#parameters (filed jenkins-infra/jenkins.io#4967) and ParamsVariable/help.jelly as well.

          Kalle Niemitalo added a comment - - edited Jenkins calls the ParameterValue.buildEnvironment method ( javadoc ), to let parameters add themselves to the environment. All the classes that extend ParameterValue and are defined in the Jenkins core do so. This feature is documented in ParametersDefinitionProperty/help.html and https://www.jenkins.io/redirect/parameterized-builds . In the Hidden Parameter Plugin, WHideParameterValue extends StringParameterValue and inherits this behavior. So, if your pipeline defines a parameter named "PATH" with the default value "http-api", I think it is by design that this sets "PATH=http-api" in the environment and prevents Jenkins from finding the git executable. However, the ParametersDefinitionProperty documentation does not look very easy to find for people creating Jenkins pipelines. It might be worth linking to the Parameterized Builds documentation from https://www.jenkins.io/doc/book/pipeline/syntax/#parameters (filed jenkins-infra/jenkins.io#4967 ) and ParamsVariable/help.jelly as well.

            Unassigned Unassigned
            faroug_aziez faroug Abdalaziz
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: