Hello,
I have been having issues with the script runner for a couple months now. I am adding a post-function script to a workflow transition and when progressing this workflow transition the issue will jump to the next status, however, filters, subscriptions and queries that display this issue will continue to show the old status.
Things to note:
- I am using this script runner on completely custom workflows
- This problem is NOT happening on every workflow transition that executes the script runner
- I have tried moving the order of this execution of the post script to AFTER the issue is reindexed with the database, however, that has proved to be unsuccessful.
- Atlassian support has recommended disabling this addon which seemed to solve the issue
- The script being run is a simple commenter that adds a comment on behalf of the user. The code was actually taken from a sample provided in Script Runner documentation pages.
Any help would be appreciated.
Regards,
Steven
Hi Steven,
If you are using JIRA 5.1 to 5.2.9, it is possible that you are experiencing a side effect of the new way that IndexManager works. For these versions, Issues are no more indexed by the Index Post-Function, but at the end of the transaction initiated for the Workflow transition.
It means that your scripts are executed with an issue not yet indexed; or changes done by these script are indexed (if indexation initiated in the script) before the indexation initiated by the Index Post-Function.
The issue is already known : JRA-31775.
It may cause error with Script Runner, but also with Auto-Transition.
See details and workaround here.
Vincent
Since 6.0, the issue is normaly fixed related multiple indexation of the same issue. The indexation doen in the correct order, but always at the end of the Transition Transaction.
If your script makes update on different issues based on value modified by a Post-Function executed in the same transition before your script, you may experience inconsistencies.
For the moment, I always use my Force Indexation post-function.
I did not yet check with latest 6.0.x releases.
V.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vincent,
I was on 5.2.5 but recently upgraded.
Do you happen to know if this issue still exists in version 6.0+?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Versions? Any errors in the log?
Provided samples can be out of date.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.