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

Rebuild plugin mangles Credentials parameters

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Component/s: credentials-plugin
    • Labels:
      None
    • Environment:
      Jenkins 1.609.1, Rebuilder 1.25, Credentials 1.22
    • Similar Issues:

      Description

      I have a job with a Credentials parameter. The default value is 'any' and the 'required' checkbox is set. A description is provided for the parameter.

      If I attempt to rebuild this job, the parameter is reset to whatever the default credential is, and the description shown on the page is the UUID of the credential selected in the previous build instead of the parameter description. See attached.

        Attachments

          Activity

          Hide
          wsaxon Will Saxon added a comment -

          FYI this is fixed by this PR

          Show
          wsaxon Will Saxon added a comment - FYI this is fixed by this PR
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Joseph Ajax
          Path:
          src/main/java/com/cloudbees/plugins/credentials/CredentialsParameterDefinition.java
          http://jenkins-ci.org/commit/credentials-plugin/f6269449ce18af7be2f013f8e2f1b6a21e1ed855
          Log:
          JENKINS-29646 - fix bug in constructor call that breaks rebuild-plugin

          -description and value parameters were swapped in constructor call causing
          the credential parameter value of the previous build to be replaced with a
          "global" default (i.e. the first credential parameter from the dropdown list)
          when triggering a rebuild.

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Joseph Ajax Path: src/main/java/com/cloudbees/plugins/credentials/CredentialsParameterDefinition.java http://jenkins-ci.org/commit/credentials-plugin/f6269449ce18af7be2f013f8e2f1b6a21e1ed855 Log: JENKINS-29646 - fix bug in constructor call that breaks rebuild-plugin -description and value parameters were swapped in constructor call causing the credential parameter value of the previous build to be replaced with a "global" default (i.e. the first credential parameter from the dropdown list) when triggering a rebuild.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Stephen Connolly
          Path:
          src/main/java/com/cloudbees/plugins/credentials/CredentialsParameterDefinition.java
          http://jenkins-ci.org/commit/credentials-plugin/5eea943175794f9b5769d23e5521a0e0cc87fb3d
          Log:
          Merge pull request #41 from jrajax/master

          JENKINS-29646 - fix bug in constructor call that breaks rebuild-plugin

          Compare: https://github.com/jenkinsci/credentials-plugin/compare/50e6fc0f7ecb...5eea94317579

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/main/java/com/cloudbees/plugins/credentials/CredentialsParameterDefinition.java http://jenkins-ci.org/commit/credentials-plugin/5eea943175794f9b5769d23e5521a0e0cc87fb3d Log: Merge pull request #41 from jrajax/master JENKINS-29646 - fix bug in constructor call that breaks rebuild-plugin Compare: https://github.com/jenkinsci/credentials-plugin/compare/50e6fc0f7ecb...5eea94317579

            People

            Assignee:
            ragesh_nair ragesh_nair
            Reporter:
            wsaxon Will Saxon
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: