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

Duplicate symbols in different plugins cause NPEs

    Details

    • Similar Issues:

      Description

      If two different plugins define the same symbol name in steps or parameters then the workflow cps plugin can't instantiate the right element.

      I.e., in JENKINS-55328 a user created a step

      recordIssues tools: [checkStyle(), pmd(pattern: 'target/pmd.xml'), spotBugs(), cpd(pattern: 'target/cpd.xml')]
      

      Since the user already installed the PMD plugin, the symbol pmd has been reserved for the step in the PMD plugin already. That means, rather then providing the pmd tool to my recordIssues step, it started the pmd step and set the corresponding array element to null.

      The same happened in JENKINS-53181. In the comments Jesse Glick noted that this behavior could not be changed (or is hard to change). It would help other plugin developers, if in such cases at least the workflow-cps engine could provide a meaningful exception (with the conflicting Jenkinsfile line) rather then assigning null to a parameter.

        Attachments

          Issue Links

            Activity

            drulli Ulli Hafner created issue -
            drulli Ulli Hafner made changes -
            Field Original Value New Value
            Assignee Share Cheng [ cizezsy ] jesse rolph [ 123jesse ]
            drulli Ulli Hafner made changes -
            Assignee jesse rolph [ 123jesse ]
            drulli Ulli Hafner made changes -
            Component/s code-coverage-api-plugin [ 23723 ]
            Component/s warnings-ng-plugin [ 24526 ]
            drulli Ulli Hafner made changes -
            Assignee Ulli Hafner [ drulli ]
            drulli Ulli Hafner made changes -
            Assignee Ulli Hafner [ drulli ]
            drulli Ulli Hafner made changes -
            Issue Type New Feature [ 2 ] Bug [ 1 ]
            drulli Ulli Hafner made changes -
            Link This issue blocks JENKINS-55328 [ JENKINS-55328 ]
            drulli Ulli Hafner made changes -
            Link This issue blocks JENKINS-53181 [ JENKINS-53181 ]
            jglick Jesse Glick made changes -
            Issue Type Bug [ 1 ] Improvement [ 4 ]
            jglick Jesse Glick made changes -
            Labels diagnostics
            jglick Jesse Glick made changes -
            Labels diagnostics diagnostics robustness
            drulli Ulli Hafner made changes -
            Link This issue relates to JENKINS-55436 [ JENKINS-55436 ]
            drulli Ulli Hafner made changes -
            Link This issue is caused by INFRA-2012 [ INFRA-2012 ]

              People

              • Assignee:
                Unassigned
                Reporter:
                drulli Ulli Hafner
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: