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

IssueFieldUpdateStep wrong fieldValue type

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • jira-plugin
    • None

      I'm trying to update a label field in Jira.

      When I use this step on the pipeline, I got the error 'RestClientException{statusCode=Optional.of(400), errorCollections=[ErrorCollection{status=400, errors=

      {customfield_12606=data was not an array}

      , errorMessages=[]}]}'

      step([$class: 'hudson.plugins.jira.pipeline.IssueFieldUpdateStep',step([$class: 'hudson.plugins.jira.pipeline.IssueFieldUpdateStep',    issueSelector: [$class: 'hudson.plugins.jira.selector.DefaultIssueSelector'],    fieldId: '12606',    fieldValue:  "some-label" ]);
      

      But when I use this step, I got another error 'java.lang.ClassCastException: hudson.plugins.jira.pipeline.IssueFieldUpdateStep.fieldValue expects class java.lang.String but received class java.util.ArrayList'

      step([$class: 'hudson.plugins.jira.pipeline.IssueFieldUpdateStep',step([$class: 'hudson.plugins.jira.pipeline.IssueFieldUpdateStep',    issueSelector: [$class: 'hudson.plugins.jira.selector.DefaultIssueSelector'],    fieldId: '12606',    fieldValue:  ["some-label"] ]);
      

            warden Radek Antoniuk
            jcwoos Julio Woos
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: