-
Bug
-
Resolution: Fixed
-
Minor
-
Jenkins 2.138.2 LTS, Git 3.9.1, Pipeline Groovy 2.59
-
Powered by SuggestiMate -
workflow-cps 2.68
For a Multibranch Pipeline job with the following configuration,
using Scripted Pipeline syntax with the following checkout step,
stage('Checkout') {
milestone()
checkout scm
}
I'm getting the following stack trace:
Error storing the arguments for step: checkout org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class jenkins.plugins.git.GitSCMSourceDefaults at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:265) at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:144) at org.jenkinsci.plugins.structs.describable.DescribableModel.of(DescribableModel.java:114) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:294) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeListAndRecordMutation(ArgumentsActionImpl.java:242) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:313) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.<init>(ArgumentsActionImpl.java:74) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:245) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:178) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:122) at sun.reflect.GeneratedMethodAccessor453.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93) at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1213) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1022) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:42) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:157) at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:23) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:155) at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:155) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:159) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129) at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.methodCall(SandboxInvoker.java:17) at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82) at sun.reflect.GeneratedMethodAccessor404.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.get(PropertyishBlock.java:76) at com.cloudbees.groovy.cps.LValueBlock$GetAdapter.receive(LValueBlock.java:30) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.fixName(PropertyishBlock.java:66) at sun.reflect.GeneratedMethodAccessor409.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.ConstantBlock.eval(ConstantBlock.java:21) at com.cloudbees.groovy.cps.Next.step(Next.java:83) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:174) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:163) at org.codehaus.groovy.runtime.GroovyCategorySupport$ThreadCategoryInfo.use(GroovyCategorySupport.java:122) at org.codehaus.groovy.runtime.GroovyCategorySupport.use(GroovyCategorySupport.java:261) at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:163) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.access$101(SandboxContinuable.java:34) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.lambda$run0$0(SandboxContinuable.java:59) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.GroovySandbox.runInSandbox(GroovySandbox.java:108) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.run0(SandboxContinuable.java:58) at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:182) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:332) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$200(CpsThreadGroup.java:83) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:244) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:232) at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:64) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131) at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28) at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
Indeed, I can see that no constructor of the GitSCMSourceDefaults class has this @DataBoundConstructor attribute, as the error says. Is this something that needs to be updated?
I mention the Disable GitHub Multibranch Status plugin we're using (this is a Test environment where we test new Jenkins plugins) in case it's actually the source of the incompatibility here.
- is related to
-
JENKINS-54032 ArgumentsActionImpl should protect against storing bizarre step arguments
-
- Closed
-
-
JENKINS-54372 NoStaplerConstructorException on jenkins.plugins.git.MergeWithGitSCMExtension
-
- Closed
-
- links to
[JENKINS-54186] No @DataBoundConstructor on any constructor of class jenkins.plugins.git.GitSCMSourceDefaults
This isn't just the Disable GitHub Multibranch Status plugin, as we don't have that installed and we've got the same error occuring. Same versions of all the plugins. I'm using the Declarative Pipeline syntax, and the following test Pipeline
pipeline { agent { label 'jenkins-builder' } stages { stage('Setup') { steps { script { sh 'env' sh 'git submodule update --init' } } } } }
Can you upload a support bundle? That provides a detailed list of installed plugins and their versions
We've just updated one of our Jenkins installations with the latest plugins, and are now observing the same error in the logs, and the following Job failures:
ERROR: [GitHub Commit Status Setter] - Cannot retrieve Git metadata for the build, setting build result to UNSTABLE
A list of installed plugins is as follows:
Plugins
Name ↓ | Version | Enabled |
---|---|---|
ace-editor | 1.1 | true |
ansicolor | 0.5.2 | true |
ant | 1.8 | true |
antisamy-markup-formatter | 1.5 | true |
apache-httpcomponents-client-4-api | 4.5.5-3.0 | true |
authentication-tokens | 1.3 | true |
aws-java-sdk | 1.11.403 | true |
bouncycastle-api | 2.17 | true |
branch-api | 2.0.20 | true |
build-name-setter | 1.6.9 | true |
build-timeout | 1.19 | true |
built-on-column | 1.1 | true |
cloudbees-folder | 6.6 | true |
command-launcher | 1.2 | true |
conditional-buildstep | 1.3.6 | true |
copyartifact | 1.41 | true |
credentials | 2.1.18 | true |
credentials-binding | 1.16 | true |
display-url-api | 2.2.0 | true |
docker-commons | 1.13 | true |
docker-workflow | 1.17 | true |
durable-task | 1.26 | true |
embeddable-build-status | 1.9 | true |
envinject | 2.1.6 | true |
envinject-api | 1.5 | true |
extended-read-permission | 2.0 | true |
external-monitor-job | 1.7 | true |
ghprb | 1.42.0 | true |
git | 3.9.1 | true |
git-client | 2.7.3 | true |
git-server | 1.7 | true |
github | 1.29.3 | true |
github-api | 1.92 | true |
github-branch-source | 2.4.1 | true |
github-oauth | 0.29 | true |
google-metadata-plugin | 0.2 | true |
google-oauth-plugin | 0.6 | true |
google-storage-plugin | 1.2 | true |
greenballs | 1.15 | true |
handlebars | 1.1.1 | true |
htmlpublisher | 1.17 | true |
jackson2-api | 2.8.11.3 | true |
javadoc | 1.4 | true |
jdk-tool | 1.1 | true |
jenkins-multijob-plugin | 1.31 | true |
jquery-detached | 1.2.1 | true |
jsch | 0.1.54.2 | true |
junit | 1.26.1 | true |
ldap | 1.20 | true |
leastload | 2.0.1 | true |
lockable-resources | 2.3 | true |
mailer | 1.22 | true |
matrix-auth | 2.3 | true |
matrix-project | 1.13 | true |
maven-plugin | 3.1.2 | true |
momentjs | 1.1.1 | true |
oauth-credentials | 0.3 | true |
pam-auth | 1.4 | true |
parameterized-trigger | 2.35.2 | true |
pipeline-build-step | 2.7 | true |
pipeline-graph-analysis | 1.7 | true |
pipeline-input-step | 2.8 | true |
pipeline-milestone-step | 1.3.1 | true |
pipeline-model-api | 1.3.2 | true |
pipeline-model-declarative-agent | 1.1.1 | true |
pipeline-model-definition | 1.3.2 | true |
pipeline-model-extensions | 1.3.2 | true |
pipeline-rest-api | 2.10 | true |
pipeline-stage-step | 2.3 | true |
pipeline-stage-tags-metadata | 1.3.2 | true |
pipeline-stage-view | 2.10 | true |
plain-credentials | 1.4 | true |
postbuildscript | 2.8.1 | true |
powershell | 1.3 | true |
resource-disposer | 0.12 | true |
run-condition | 1.2 | true |
s3 | 0.11.2 | true |
scm-api | 2.3.0 | true |
script-security | 1.47 | true |
slack | 2.3 | true |
ssh-credentials | 1.14 | true |
structs | 1.17 | true |
swarm | 3.14 | true |
timestamper | 1.8.10 | true |
token-macro | 2.5 | true |
windows-slaves | 1.3.1 | true |
workflow-aggregator | 2.6 | true |
workflow-api | 2.30 | true |
workflow-basic-steps | 2.11 | true |
workflow-cps | 2.59 | true |
workflow-cps-global-lib | 2.12 | true |
workflow-durable-task-step | 2.24 | true |
workflow-job | 2.25 | true |
workflow-multibranch | 2.20 | true |
workflow-scm-step | 2.7 | true |
workflow-step-api | 2.16 | true |
workflow-support | 2.21 | true |
ws-cleanup | 0.36 | true |
yaml-axis | 0.2.0 | true |
And the plugins that got updated this morning:
Plugin | Current Version | Previous Version |
---|---|---|
github | 1.29.3 | 1.29.2 |
github-branch-source | 2.4.1 | 2.3.6 |
htmlpublisher | 1.17 | 1.16 |
mailer | 1.22 | 1.21 |
scm-api | 2.3.0 | 2.2.8 |
script-security | 1.47 | 1.46 |
structs | 1.17 | 1.15 |
workflow-aggregator | 2.6 | 2.5 |
workflow-api | 2.30 | 2.29 |
workflow-cps | 2.59 | 2.56 |
workflow-cps-global-lib | 2.12 | 2.11 |
workflow-durable-task-step | 2.24 | 2.22 |
workflow-scm-step | 2.7 | 2.6 |
workflow-support | 2.21 | 2.20 |
ws-cleanup | 0.36 | 0.34 |
markewaite, I removed the Disable GitHub Multibranch Status configuration from this multibranch job (but left the plugin itself installed in this Jenkins system) and reran it, and still get the same @DataBoundConstructor exception in the logs. Given that, it seems conceivable that that's still the plugin at fault here, but less likely. I'm reluctant to remove the plugin entirely since we leverage it for running builds on this test Jenkins instance (without muddying the notifications in GitHub). I also note that that plugin does have the @DataBoundConstructor on its constructor, unlike the constructor for GitSCMSourceDefaults in the main Git plugin.
markewaite So I'm playing whack-a-mole with Plugins atm, to try and identify which plugin upgrade broke things for us...
So far, I've ruled out:
- scm-api
- workflow-scm-step
- github-branch-source
- github
Edit: So after downgrading the github plugin, the exceptions are still being logged, however the Commit status' are now being updated correctly...
So I'm not sure on the cause and effect there...
Judging from the call changes, it might be the work in https://github.com/jenkinsci/workflow-cps-plugin/pull/257 that did this?
I downgraded workflow-cps to 2.58 (from https://updates.jenkins.io/download/plugins/workflow-cps/) and it all appears to be working again
Thanks palfrey – I downgraded workflow-cps (aka Pipeline: Groovy) plugin to 2.58 and the exceptions have stopped. I've updated the component here accordingly.
svanoort, is the fix for this to apply a @DataBoundConstructor annotation on the constructor of GitSCMSourceDefaults?
I am having this issue as well, or similar. After upgrading cps plugin I get this:
Error storing the arguments for step: checkout org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class jenkins.plugins.git.AbstractGitSCMSource$SpecificRevisionBuildChooser at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:265) at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:144) at org.jenkinsci.plugins.structs.describable.DescribableModel.of(DescribableModel.java:114) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:294) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeListAndRecordMutation(ArgumentsActionImpl.java:242) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:313) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.<init>(ArgumentsActionImpl.java:74) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:245) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:178) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:122) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:48) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:20) at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82) at sun.reflect.GeneratedMethodAccessor124.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.get(PropertyishBlock.java:76) at com.cloudbees.groovy.cps.LValueBlock$GetAdapter.receive(LValueBlock.java:30) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.fixName(PropertyishBlock.java:66) at sun.reflect.GeneratedMethodAccessor284.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.ConstantBlock.eval(ConstantBlock.java:21) at com.cloudbees.groovy.cps.Next.step(Next.java:83) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:174) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:163) at org.codehaus.groovy.runtime.GroovyCategorySupport$ThreadCategoryInfo.use(GroovyCategorySupport.java:129) at org.codehaus.groovy.runtime.GroovyCategorySupport.use(GroovyCategorySupport.java:268) at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:163) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.access$101(SandboxContinuable.java:34) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.lambda$run0$0(SandboxContinuable.java:59) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.GroovySandbox.runInSandbox(GroovySandbox.java:108) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.run0(SandboxContinuable.java:58) at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:182) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:332) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$200(CpsThreadGroup.java:83) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:244) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:232) at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:64) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131) at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28) at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class jenkins.plugins.git.MergeWithGitSCMExtension at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:265) at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:144) at org.jenkinsci.plugins.structs.describable.DescribableModel.of(DescribableModel.java:114) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:294) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeListAndRecordMutation(ArgumentsActionImpl.java:242) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:313) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.<init>(ArgumentsActionImpl.java:74) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:245) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:178) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:122) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:48) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:20) at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82) at sun.reflect.GeneratedMethodAccessor124.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.get(PropertyishBlock.java:76) at com.cloudbees.groovy.cps.LValueBlock$GetAdapter.receive(LValueBlock.java:30) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.fixName(PropertyishBlock.java:66) at sun.reflect.GeneratedMethodAccessor284.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.ConstantBlock.eval(ConstantBlock.java:21) at com.cloudbees.groovy.cps.Next.step(Next.java:83) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:174) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:163) at org.codehaus.groovy.runtime.GroovyCategorySupport$ThreadCategoryInfo.use(GroovyCategorySupport.java:129) at org.codehaus.groovy.runtime.GroovyCategorySupport.use(GroovyCategorySupport.java:268) at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:163) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.access$101(SandboxContinuable.java:34) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.lambda$run0$0(SandboxContinuable.java:59) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.GroovySandbox.runInSandbox(GroovySandbox.java:108) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.run0(SandboxContinuable.java:58) at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:182) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:332) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$200(CpsThreadGroup.java:83) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:244) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:232) at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:64) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131) at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28) at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
I had rolled back to 2.58 to avoid the issue tracked here, but now see a 2.60 release fixing a security issue. I'd rather not upgrade and start getting these errors again but also am loath to ignore a security fix. Could someone give me some guidance as to whether the problem reported here is fixable? AFAIK the only actual impact of this bug is large stack traces in the logs – not actual functional problems – but I'd rather avoid excessive log noise if I can.
MergeWithGitSCMExtension and GitSCMSourceDefaults deliberately lack descriptors and are not intended to be databound. This is a bug in ArgumentsActionImpl resulting from the fix of JENKINS-54032. I suspect something like
diff --git a/src/main/java/org/jenkinsci/plugins/workflow/cps/actions/ArgumentsActionImpl.java b/src/main/java/org/jenkinsci/plugins/workflow/cps/actions/ArgumentsActionImpl.java index dd292481..0bacdc36 100644 --- a/src/main/java/org/jenkinsci/plugins/workflow/cps/actions/ArgumentsActionImpl.java +++ b/src/main/java/org/jenkinsci/plugins/workflow/cps/actions/ArgumentsActionImpl.java @@ -291,6 +291,9 @@ public class ArgumentsActionImpl extends ArgumentsAction { } else if (tempVal instanceof UninstantiatedDescribable) { tempVal = ((UninstantiatedDescribable)tempVal).toMap(); } else if (tempVal instanceof Describable) { // Raw Describables may not be safe to store, so we should explode it + if (Jenkins.get().getDescriptor(tempVal.getClass().asSubclass(Describable.class)) == null) { + return NotStoredReason.UNSERIALIZABLE; + } m = DescribableModel.of(tempVal.getClass()); tempVal = m.uninstantiate2(o).toMap(); }
would fix it, but the issue needs to be reproduced in a functional test first.
the only actual impact of this bug is large stack traces in the logs – not actual functional problems
More or less, yes. There is a bit of a functional problem but you are unlikely to care about the impact. Certainly not worth giving up the critical security fix for.
Yes, this is purely a log-spam issue – we catch all exceptions from trying to store step arguments. Jesse's comment sparks some ideas for me.
I suppose the simplest “fix” would just be to log NoStaplerConstructorException at FINE.
I have a fix for the logspam, but am still working on the testcase (a bit fiddly).
This is not just a log spam issue, this is preventing the BitbucketBuildStatusNotifier plugin from updating build statuses, as the commit information does not exist.
WARNING: Error storing the arguments for step: checkout org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class jenkins.plugins.git.GitSCMSourceDef aults at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:265) at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:144) at org.jenkinsci.plugins.structs.describable.DescribableModel.of(DescribableModel.java:114) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:294) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeListAndRecordMutation(ArgumentsActionImpl.java:242) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:313) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.<init>(ArgumentsActionImpl.java:74) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:243) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:176) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:122) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:48) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:20) at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82) at sun.reflect.GeneratedMethodAccessor215.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.get(PropertyishBlock.java:76) at com.cloudbees.groovy.cps.LValueBlock$GetAdapter.receive(LValueBlock.java:30) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.fixName(PropertyishBlock.java:66) at sun.reflect.GeneratedMethodAccessor220.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.ConstantBlock.eval(ConstantBlock.java:21) at com.cloudbees.groovy.cps.Next.step(Next.java:83) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:174) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:163) at org.codehaus.groovy.runtime.GroovyCategorySupport$ThreadCategoryInfo.use(GroovyCategorySupport.java:129) at org.codehaus.groovy.runtime.GroovyCategorySupport.use(GroovyCategorySupport.java:268) at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:163) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.access$101(SandboxContinuable.java:34) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.lambda$run0$0(SandboxContinuable.java:59) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.GroovySandbox.runInSandbox(GroovySandbox.java:121) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.run0(SandboxContinuable.java:58) at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:182) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:332) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$200(CpsThreadGroup.java:83) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:244) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:232) at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:64) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131) at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28) at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)Feb 04, 2019 10:51:10 AM org.jenkinsci.plugins.bitbucket.BitbucketBuildStatusNotifierStep$Execution run INFO: Got commit id null Feb 04, 2019 10:51:10 AM org.jenkinsci.plugins.bitbucket.BitbucketBuildStatusNotifierStep$Execution run INFO: Got repo slug = null Feb 04, 2019 10:51:10 AM org.jenkinsci.plugins.bitbucket.scm.GitScmAdapter getCommitRepoMap WARNING: Build data could not be found
yeah after looking into it further I think you're right, it just looks like it's related
javabudd did you find any solution cause, we had to downgrade from git plugin 4.0.0-rc also to 3.9.x to get bitbucket notifications working again?
This is the only related issue I can find with workflow-cps 2.63 we're hitting:
I'm happy to open a new issue if needed, but if it's related just wanted to see if there's any additional work arounds that have been found. Downgrading to 2.58 causes a range of other dependency issues.
Error storing the arguments for step: checkoutError storing the arguments for step: checkoutorg.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class jenkins.plugins.git.AbstractGitSCMSource$SpecificRevisionBuildChooser at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:265) at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:144) at org.jenkinsci.plugins.structs.describable.DescribableModel.of(DescribableModel.java:114) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:294) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeListAndRecordMutation(ArgumentsActionImpl.java:242) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:313) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeObjectAndRecordMutation(ArgumentsActionImpl.java:311) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.sanitizeMapAndRecordMutation(ArgumentsActionImpl.java:386) at org.jenkinsci.plugins.workflow.cps.actions.ArgumentsActionImpl.<init>(ArgumentsActionImpl.java:74) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:243) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:176) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:122) at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:48) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:20) at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109) at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82) at sun.reflect.GeneratedMethodAccessor297.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.get(PropertyishBlock.java:76) at com.cloudbees.groovy.cps.LValueBlock$GetAdapter.receive(LValueBlock.java:30) at com.cloudbees.groovy.cps.impl.PropertyishBlock$ContinuationImpl.fixName(PropertyishBlock.java:66) at sun.reflect.GeneratedMethodAccessor302.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72) at com.cloudbees.groovy.cps.impl.ConstantBlock.eval(ConstantBlock.java:21) at com.cloudbees.groovy.cps.Next.step(Next.java:83) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:174) at com.cloudbees.groovy.cps.Continuable$1.call(Continuable.java:163) at org.codehaus.groovy.runtime.GroovyCategorySupport$ThreadCategoryInfo.use(GroovyCategorySupport.java:129) at org.codehaus.groovy.runtime.GroovyCategorySupport.use(GroovyCategorySupport.java:268) at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:163) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.access$101(SandboxContinuable.java:34) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.lambda$run0$0(SandboxContinuable.java:59) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.GroovySandbox.runInSandbox(GroovySandbox.java:121) at org.jenkinsci.plugins.workflow.cps.SandboxContinuable.run0(SandboxContinuable.java:58) at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:182) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:332) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$200(CpsThreadGroup.java:83) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:244) at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:232) at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:64) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131) at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28) at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
intheclouddan yes your message is basically the same as that originally reported here; the same fix would cover both. See my comments of 2018-11-01. There is no workaround beyond ignoring the warnings.
Is there a known workaround to hide these exceptions?
I have tried to add a Groovy init script with this:
import java.util.logging.Logger import java.util.logging.Level Logger.getLogger("org.jenkinsci.plugins.workflow.cps.DSL").setLevel(Level.OFF)
But this is not making any changes to the log levels
Edit:
Ok, I found the issue, I need to remove DSL from there. This works:
import java.util.logging.Logger import java.util.logging.Level Logger.getLogger("org.jenkinsci.plugins.workflow.cps").setLevel(Level.SEVERE)
michelzanini did you run your script in the Script Console or as part of a build (or somewhere else entirely)? I wonder if defining a log level via the UI for the same namespace and severity would have the same effect?
Never mind – I realized what you're describing is the technique documented at https://wiki.jenkins.io/display/JENKINS/Post-initialization+script. I've created an init.groovy in $JENKINS_HOME with the content from michelzanini's last comment, bounced my Jenkins instance, and am no longer seeing this log spam. Thanks!
Yes medianick, I used as init script. And is true that you might be hiding other logs like mentioned by conn. I don't see it as a major issue to hide more. But need to keep this in mind. Anyway, its the only workaround that can be done.
markewaite as in JENKINS-43802 is there some reason you changed the Status here?
Sorry for a second mistake jglick. Back to closed, it was resolved and delivered earlier as the comments say.
Thanks for a clear bug report. Much appreciated!
I can't duplicate the problem with the systems currently available to me. I've created a test job which uses `milestone` and `checkout scm` as described in the bug report and have run it successfully in several different multibranch Pipelines on my test server.
I don't have convenient access to install the Disable GitHub Multibranch Status plugin on that test server. The hotel where I'm staying on business travel blocks my ssh access to my test servers at home.
Could you attempt to run your failing Declarative Pipeline on a server which does not have the 'Disable GitHub Multibranch Status' plugin installed?
I won't be able to explore this further for at least another two weeks due to business and personal travel.
In the interest of full disclosure, I ran my tests on the latest released versions of all the workflow plugins and the latest pre-release of the git plugin and git client plugin. The specific plugin binaries I used are on the lts-with-plugins branch of my docker-lfs repository.