Upgraded from Jira 4.0.1 to Jira 5.1.2 - error when reopening closed issue - Unable to update custom field

error : Unable to update custom field 'customfield_10371' ....

The interesting thing about this error is that the custom field listed is not valid for this issue type.

I have upgraded to Jira Suite Utilities to version 1.3.2.

From the log: com.opensymphony.workflow.WorkflowException: Unable to update custom field customfield_10371 - <custom field name> in issue [ERX-*****].
at com.googlecode.jsu.workflow.function.UpdateIssueCustomFieldPostFunction.executeFunction(UpdateIssueCustomFieldPostFunction.java:94)
at com.googlecode.jsu.workflow.function.AbstractPreserveChangesPostFunction.execute(AbstractPreserveChangesPostFunction.java:59)
at com.opensymphony.workflow.AbstractWorkflow.executeFunction(AbstractWorkflow.java:1050)
at com.opensymphony.workflow.AbstractWorkflow.transitionWorkflow(AbstractWorkflow.java:1446)
at com.opensymphony.workflow.AbstractWorkflow.doAction(AbstractWorkflow.java:564)
at com.atlassian.jira.workflow.OSWorkflowManager.doWorkflowActionInsideTxn(OSWorkflowManager.java:894)
at com.atlassian.jira.workflow.OSWorkflowManager.doWorkflowAction(OSWorkflowManager.java:850)
at com.atlassian.jira.bc.issue.DefaultIssueService.transition(DefaultIssueService.java:449)
at com.atlassian.jira.web.action.issue.CommentAssignIssue.doExecute ...

.

9 answers

1 accepted

The work around to remove the restriction of the issue types and make it valid for all issues allowed the Post function to work. We will also test the script runner suggested by Renjith

It seems to me that you have to check the customfield id and make sure the customfield is valid for that issue type

0 votes
Renjith Pillai Community Champion Jan 10, 2013
  • Tried integrity checker?
  • Does this happen with safe mode enabled?

Thanks Louis, The issue type is not valid for this custom field. In addition, I found that there is a post function that appears to set a default value during the reopen. After seeing the post function I expected this to fail in JIRA 4.0.1 also but it did not. Something may have changed with the Jira Suite Utilities plugin.

The problem here is that the custom field is only valid for 2 issue types (we have 7 issue types). For an invalid issue type, it tries to set the value on the post function which is why it fails. It didn't fail in 4.0.1, but it does in 5.1.2 now.

I guess we need two separate workflows, one for issues types with customfield_10371, and one for issue types without that custom field, then the workflow scheme is used to decide which workflow for which issue type.

The problem now is maintenance. We essentially have two identical workflows that only differ by a single post function.

Or is there a better way to manage the workflows?

Thanks!

;D

The problem here is that the custom field is only valid for 2 issue types (we have 7 issue types). For an invalid issue type, it tries to set the value on the post function which is why it fails. It didn't fail in 4.0.1, but it does in 5.1.2 now.

I guess we need two separate workflows, one for issues types with customfield_10371, and one for issue types without that custom field, then the workflow scheme is used to decide which workflow for which issue type.

The problem now is maintenance. We essentially have two identical workflows that only differ by a single post function.

Or is there a better way to manage the workflows?

Thanks!

;D

The workaround that Darren mentioned above (i.e. making the field valid for all issue types) fixes the problem with post function failing. However, we would still like to know if there is a better way to manage this with workflows rather than having 2 workflows that are almost the identical.

0 votes
Renjith Pillai Community Champion Jan 16, 2013

The only way I can think of is again the Script Runner which can have an if condition to update the field only if the issue type is a specific one. Otherwise I am afraid that you should have different workflows.

Thanks Renjith, we will give the Script Runner a try.

;D

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,847 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot