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

"affectedPaths" returns relative path and not absolute path

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Not A Defect
    • Icon: Minor Minor
    • git-plugin
    • None
    • Jenkins 2.375.4

      When using REST APIs to check "affectedpaths", we get relative path from repositiry and NOT the complete path.
      Sample command:

      https://jenkins.<company>.com/job/<jobname>/<buildnumber>/api/json?pretty=true&tree=result,changeSets[items[comment,affectedPaths,affectedfiles,msg,url,commitId,url,timestamp,authorEmail]

      This shows:

      "affectedPaths" : [
      "dir1/dir2/file1",
      "dir3/dir4/file2",
      ]

      While the expected output is:

      "affectedPaths" : [
      "https://gerrit.<company>.com/c/parentdir/dir1/dir2/file1",
      "https://gerrit.<company>.com/c/parentdir/dir3/dir4/file2",
      ]

            Unassigned Unassigned
            vrukesh Vrukesh
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: