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

Unable to download JiraUploadAttachment created attachment

    Details

    • Type: Improvement
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: jira-steps-plugin
    • Labels:
      None
    • Environment:
      Jenkins LTS 2.222.3 on Windows
      jira-steps-plugin 1.6.0
      Jira both on premise trial on linux using docker or atlassian cloud
    • Similar Issues:

      Description

      I'm unable to download an attachment created using the JiraUploadAttachment pipeline command.

      The Jenkins 2.222.3 I'm using is running on Windows 10 with the jira-steps-plugin 1.6.0 installed.

      Here is a pipeline snippet:

        jiraUploadAttachment idOrKey: 'NP-56', file: 'SRReport.zip', site: 'trial'
        echo attachment.data.toString()

      Both the issue and the attachment are successfully created, as it is visible on the Job output:

      id:10115, key:NP-56, self:[http://jira.xxxx.net/rest/api/2/issue/10115 [Pipeline] jiraUploadAttachment JIRA: Site - test - Attaching file: D:\Jenkins\jobs\My Pipeline\workspace\SRReport.zip to NP-56 Successful. Code: 200

      I can see the attachment opening the Jira task, but the link is using the full path and it is not downloadable, getting an error 400

      Message Invalid URI

      Description The server cannot or will not process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).

      I was not able to find how to change the uploaded file name to not contain the full path

       

        Attachments

          Activity

          There are no comments yet on this issue.

            People

            • Assignee:
              bpelaia Bruno Pelaia
              Reporter:
              bpelaia Bruno Pelaia
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated: