• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • pipeline

      If you have a Java object array (as opposed to a list, as with typical Groovy code) and try to pass it as an argument to a CPS-transformed method, only the first element arrives, rather than an array.

      Workarounds:

      • wrap the array in Arrays.asList before passing it, and treat the argument as a List
      • annotate the method as @NonCPS (assuming it is not calling any steps)

          [JENKINS-32062] Arrays may not be passed directly to methods

          Jesse Glick created issue -
          Jesse Glick made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Jesse Glick made changes -
          Remote Link New: This issue links to "groovy-cps PR 20 (Web Link)" [ 13599 ]
          Jesse Glick made changes -
          Link New: This issue is duplicated by JENKINS-29990 [ JENKINS-29990 ]
          Jesse Glick made changes -
          Remote Link New: This issue links to "PR 295 (Web Link)" [ 13741 ]
          SCM/JIRA link daemon made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: In Progress [ 3 ] New: Resolved [ 5 ]
          Jesse Glick made changes -
          Link New: This issue is duplicated by JENKINS-32122 [ JENKINS-32122 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 167538 ] New: JNJira + In-Review [ 198225 ]
          Andrew Bayer made changes -
          Component/s New: pipeline-general [ 21692 ]
          Andrew Bayer made changes -
          Component/s Original: workflow-plugin [ 18820 ]

            jglick Jesse Glick
            jglick Jesse Glick
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: