No longer able to attach files on closed issues in 6.4

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 29, 2015

We just upgraded from JIRA 6.1.3 to 6.4.7.  In one of my workflows, I set it up so that users can only edit certain fields and add attachments after the issue is closed.  I have jira.issue.editable = false on the Closed status.  I have workflow transitions "Edit Fields" and "Attach" that control that behaviour by limiting the fields to be edited. 

Prior to the upgrade these worked just fine.  After the upgrade, the "Edit Fields" workflow step works just fine using a transition screen with the limited fields that can be edited.  However the "attach" no longer works.  The attachment field will be displayed and it allows you to select the file.  But when you select "attach" to process the workflow transition it just returns silently to the screen.  It does not attach the file and does not give a user a warning.  In the log file you get a WARN:

2015-07-29 20:14:37,214 http-bio-8080-exec-15376 WARN shauth 1214x1053858x4 x2da7x 10.9.30.110 /secure/CommentAssignIssue.jspa [jira.issue.fields.AttachmentSystemField] There were errors while converting temporary attachments: AttachmentError{logMessage='An error occurred: You can not create attachments as the issue is in a non-editable workflow state.', localizedMessage='You can not create attachments as the issue is in a non-editable workflow state.', filename='', reason=VALIDATION_FAILED, exception=none()}

I'm looking for a workaround and also an understanding of why this no longer works in JIRA 6.4

3 answers

1 accepted

1 vote
Answer accepted
Andy Nguyen
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 30, 2015

Hi Susan & Robert,

The warning message attached points me to this Bug: Cannot add attachments when closing issues

It was unfortunately introduced in JIRA 6.4.x sad

3 votes
Robert Dzido
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 29, 2015

you can use another step property:

key: jira.permission.edit.group

value: none (or just another text - not matching any group). If you put for example jira-administrators instead of "none", only members of jira-administrators will be able to edit the issue in this particular step (of course if allowed in permission scheme).

 

This also causes that "attach" options are still available in "More actions" menu.

 

Regards,

Robert

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

Hi, I tried that and it still did not work. 2015-07-30 18:48:10,459 http-bio-8080-exec-19510 WARN shauth 1128x1414591x4 ismq4e 10.9.30.109 /secure/CommentAssignIssue.jspa [jira.issue.fields.AttachmentSystemField] There were errors while converting temporary attachments: AttachmentError{logMessage='An error occurred: You can not create attachments as the issue is in a non-editable workflow state.', localizedMessage='You can not create attachments as the issue is in a non-editable workflow state.', filename='', reason=VALIDATION_FAILED, exception=none()} :-(

Robert Dzido
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 30, 2015

Susan, Can you please paste your workflow step properties here?

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

See below for the transition property. I think I found a workaround. I changed the workflow to go back to Open and then fast track back to close. So while it's "open" I can attach a file and then the post workflow transition sends it to Close. It's just so strange that I can edit fields using a workflow transition while the issue is closed without any properties on the transition. And it works for all the fields EXCEPT the attachments. It's also strange as this was not a problem prior to the upgrade. Thanks Robert

Jose M.
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 9, 2016

Thanks for the suggestion with property key: jira.permission.edit.group. This is working for us.

Deleted user May 15, 2019

@Susan Hauth _Jira Queen_ Susan Hauth, I'm trying to follow your suggestion. I have a reviewer sub-task with a workflow "Approved with Comments". They presently can't attach files (like a list of comments), much like the problem described here.

So, I have the "Approved with Comments" go back to "Open" like you suggested, and at the Open state, I have it Fast Track to the desired "Approved with Comments" final state. I named that transition "Fast Track" and it uses the Scriptrunner Fast Track an issue function. This allows me to attach a file at the "Approved with Comments" transition, but it's then left in an "Open" state with a workflow button named "Fast Track". In other words, this is not seamlessly, automatically transitioning from when the user clicks "Approve with Comments" on their sub-tasks to "Open" (and using Fast Track) to the desired state of "Approved with Comments". 

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 15, 2019

Hi Chris,

This was a bug in the 6.4 (or around that) version.  That is no longer an issue after version 7.  Are you able to upgrade?

Susan

Deleted user May 16, 2019

I'm at Jira version 7.13.0. Scriptrunner version Version:5.5.6. These are pretty much the latest releases.

The users have "Create File" permissions. I've recreated the problem and I'm an Administrator. Should I put this in as a Support Request? It's a workflow window that only includes the "attachment" (system) field and the "Comment" field. When they click the button to "Approve with Comments" in that workflow window (with the attachment file selected), it appears as though the file is uploading (there's a progress bar indicating so), but then the sub-task is resolved as "Approved with Comments"....but no attachment.

We've tried seven ways from Sunday to implement the Scriptrunner "fast track"...even unpublished "isAutomaticTransition()" Boolean, but no joy.

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 16, 2019

Hi Chris,

I'm going to suggest you raise a new question and tag it with scriptrunner, so the scriptrunner experts can take a look.

Susan

Like Deleted user likes this
Deleted user May 16, 2019

Thanks Susan, for now, I've decided to pursue this as a support ticket with Atlassian, since the ability to attach files in a workflow window (for the reviewer sub-task) was working fine in our previous version of Jira - so maybe there's a solution from Atlassian. I'll post it here if it's something relateable. 

0 votes
Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

Transition Property.PNG

Robert Dzido
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 30, 2015

It's TRANSITION property, NOT STEP property. Please put it to STEP property :)

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

But I don't want it in the step property. Because I don't want these fields to be editable except under certain conditions (parent statuses) and only by the reporter.

Robert Dzido
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 30, 2015

So, add conditions to your transition and property to step. transition properties work in another way

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

I do have conditions on the transitions and properties on that step. The problem was that prior to JIRA 6.4.7 I was able to use a workflow transition to open up the attachments,allow an attachment and close. And it worked fine. Now it doesn't and I did not make any changes to this workflow post upgrade.

Robert Dzido
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 30, 2015

So, they fixed it in 6.4. Simply replace your old step property with the new one. Do not change any other options

Susan Hauth _Jira Queen_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 30, 2015

IMHO I think they broke something in JIRA 6.4.

Lacey McDonnell May 30, 2017

I can't get this to work on 6.4.11 ... I am in the Edit Closed Group but Attachments field is missing on edit screen and in MORE dropdown.

 

Edit-Allowed-Group.PNG

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 30, 2017

You still need the permission to attach files in the project.

Suggest an answer

Log in or Sign up to answer