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

Jenkins 2.0 JSON API returns empty array elements in build "actions" array

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • core
    • Jenkins WAR: org.jenkins-ci.main:jenkins-war:2.0-beta-1
      Platform: Debian wheezy

      API responses for builds return include "actions" arrays, which are now containing both objects and arrays as elements. Prior to 2.0 this was not the case. E.g:

      {
      "actions" : [
      {

      },
      [

      ],
      {
      "causes" : [

      { "shortDescription" : "Started by upstream project \"authy_master\" build number 120", "upstreamBuild" : 120, "upstreamProject" : "authy_master", "upstreamUrl" : "job/authy_master/" }

      ]
      },
      {

      },
      ...

      Note the second element there is an empty array. Is this WAD? Returning JSON in such a format makes response parsing much more difficult.

            Unassigned Unassigned
            zoetermeer James Swaine
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: