This is actually just a question of general curiosity.
I noticed there's potential for transitions in separate workflows to have the same ID and wanted to be sure this wouldn't cause any conflicts... specifically as it relates to Script Runner scripts (fast tracking).
This could easily happen if you build a workflow in a dev environment and migrate it to production.
If this can cause problems, what's a general solution/workaround?
Yeah it's fine... the ID used in a param to a SR function will refer to the ID of an action in the current workflow, unless otherwise made clear.
Thanks again for the clarification!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There might be an issue with Behaviour's Conditions and transition IDs:
I have two different Behaviours - mapped to all projects and all IssueTypes - for defining when comments are mandatory by transition IDs:
def commentField = getFieldById("comment") log.debug("BEHAVIOUR 1 IS ACTIVE") commentField.setHelpText("Please leave a comment (BEHAVIOUR 1)")
def commentField = getFieldById("comment") log.debug("BEHAVIOUR 2 IS ACTIVE") commentField.setHelpText("Please leave a comment (BEHAVIOUR 2)")
Both are assigned to "Field: Comment" and have Conditions for which transition they should get triggered for two different guide workflows (options: Required, Writable and Shown).
Lets say for Workflow 1, which is assigned to Behaviour 1 it should be triggered for transition IDs 1-10. Conditions:
Workflow 1 additionally has a transition Set to REOPENED (31) which is not mentioned in Behaviour1
For workflow 2, assigned to Behaviour 2, Conditions are the transition IDs 30-40
Now if I transition an Issue in workflow 1 and the transition ID is e.g. 31 (in range of workflow 2) i get the following logs:
BEHAVIOUR 1 IS ACTIVE //I think that is the ID check BEHAVIOUR 2 IS ACTIVE //I dont know why this should be triggered in guideworkflow1
and the comment field is set mandatory with helptext "Please leave a comment (BEHAVIOUR 2)"
even if transition ID 31 for workflow 1 is "Set to REOPENED" (differently named)
and transition ID 31 for workflow 2 is "Set to RESOLVED" (!= Set to IN_PROGRESS)
I think the behaviour gets triggered by the matching transition ID, even if the guide workflow is a different one, and the transition names are different.
Is this an reproducible issue or am I missing sth in my instance here?
ScriptRunner 4.3.12
Greetings to @Adaptavist =)
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.