jenkinsci / jenkinsci/structs-plugin

[JENKINS-34173] DescribableModel rejects PasswordParameterValue due to use of Secret

Open
#273 3 comments 0 reactions 0 assignees View on GitHub
component:structs-plugin imported-jira-issue pipeline priority:minor resolution:unresolved
Dominant language
Java
Stars
11
Forks
33
PR merge metrics
No merged PRs in 30d

Description

When trying to generate a snippet to build a job which has a password parameter through the pipeline plugin it refuses to generate the snippet.

in the jenkins.log an error is logged:

Caused by: org.kohsuke.stapler.NoStaplerConstructorException: There's no @​DataBoundConstructor on any constructor of class hudson.util.Secret

at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:177)

at org.jenkinsci.plugins.structs.describable.DescribableModel.(DescribableModel.java:105)

at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)

at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:164)

at org.jenkinsci.plugins.structs.describable.DescribableParameter.inspect(DescribableParameter.java:112)

at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate(DescribableModel.java:426)

at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)

at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:164)

at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:158)

at org.jenkinsci.plugins.structs.describable.DescribableParameter.inspect(DescribableParameter.java:112)

at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate(DescribableModel.java:426)

at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)

at org.jenkinsci.plugins.workflow.steps.StepDescriptor.defineArguments(StepDescriptor.java:114)

at org.jenkinsci.plugins.workflow.cps.Snippetizer.object2Groovy(Snippetizer.java:68)

at org.jenkinsci.plugins.workflow.cps.Snippetizer.doGenerateSnippet(Snippetizer.java:218)

... 78 more

---
Originally reported by visibilityspots, imported from: DescribableModel rejects PasswordParameterValue due to use of Secret


  • assignee: jglick
  • status: Open
  • priority: Minor
  • component(s): structs-plugin
  • label(s): pipeline
  • resolution: Unresolved
  • votes: 0
  • watchers: 2
  • imported: 20260604-211335

Raw content of original issue

When trying to generate a snippet to build a job which has a password parameter through the pipeline plugin it refuses to generate the snippet.

in the jenkins.log an error is logged:

Caused by: org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class hudson.util.Secret
at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:177)
at org.jenkinsci.plugins.structs.describable.DescribableModel.<init>(DescribableModel.java:105)
at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)
at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:164)
at org.jenkinsci.plugins.structs.describable.DescribableParameter.inspect(DescribableParameter.java:112)
at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate(DescribableModel.java:426)
at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)
at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:164)
at org.jenkinsci.plugins.structs.describable.DescribableParameter.uncoerce(DescribableParameter.java:158)
at org.jenkinsci.plugins.structs.describable.DescribableParameter.inspect(DescribableParameter.java:112)
at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate(DescribableModel.java:426)
at org.jenkinsci.plugins.structs.describable.DescribableModel.uninstantiate_(DescribableModel.java:466)
at org.jenkinsci.plugins.workflow.steps.StepDescriptor.defineArguments(StepDescriptor.java:114)
at org.jenkinsci.plugins.workflow.cps.Snippetizer.object2Groovy(Snippetizer.java:68)
at org.jenkinsci.plugins.workflow.cps.Snippetizer.doGenerateSnippet(Snippetizer.java:218)
... 78 more

environment

```
Jenkins ver. 1.650

Pipeline plugin 2.0
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.