JIRA Manual automation - trigger manual transition through workflow

Adrian Szubert July 5, 2024

Hi!

 

I have once again questions about JIRA automation and issue transitions.

 

I have created a JIRA automation to generate a QA Task based on the parent Story status - if the Parent reaches a certain status, it generates a QA Task and puts it in a starting status of the workflow.

As I know that automation cannot trigger another automation, I want to create manually triggered automation to initiate a change from starting status to mirror the same status of a Parent story (skipping the need to push it manually through the whole workflow).

The relation between those is set to Parent-Child (where Story is Parent, and QA Task is Child). Everything I try results in setting the starting status on QA Task (so e.g. from TODO to TODO), or results in an error that destination status cannot be reached.

I thought that would be very easy automation, but it is way more complex than expected.

I am looking forward to your support!

BR,

ASZ

 

 

3 answers

2 accepted

0 votes
Answer accepted
Adrian Szubert July 6, 2024

Hello @Trudy Claspill 

 

Thank you for such a clear explanation. I tried to mirror what you have provided (by the way, it is very impressive what you can do in JIRA). As my knowledge using smart values is close to none, I had some struggles even to get the config running, but in the end, it goes - unfortunately throwing errors, due to an invalid operator. Please find the following:

image.pngimage.pngIn regards to your question about the post - it was a few months ago, and after reading the post @Bill Sheboy (thank you very much for such an explanation!), I may have understood it the wrong way.

 

Would you mind supporting me one more time to have that automation working? That's also great learning material!

0 votes
Answer accepted
Trudy Claspill
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 5, 2024

Hello @Adrian Szubert 

Welcome to the Atlassian community.

Where are you getting the information that an automation can't trigger another automation? You have gotten incorrect information.

The actions taken by an Automation Rule can trigger another Automation Rule. If Rule A creates an issue, and Rule B is triggered by creation of an issue, then Rule B can be triggered by the action of Rule A.

There is a checkbox on the Rule Details page of each rule that must be checked in order for this to occur.

Screenshot 2024-07-05 at 8.39.50 AM.png

 

Is the QA Task an issue type within the Sub-task category? Or is the parent/child relationship created through generic issue linking?

If the QA Task is a Sub-task then you would use a rule like this:

Screenshot 2024-07-05 at 8.59.15 AM.png

Trudy Claspill
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 6, 2024

Copying my previous responses into my Answer thread 

 I found one of the Atlassian Community answers (that was the top answer in this subject) that was pointing exactly to this limitation - JIRA automation cannot trigger another JIRA automation.

 

Can you provide a link to that post/answer? I want to add a comment to it if it has incorrect information.

 

Please provide screen images that show the complete Automation Rule that you use to create the QA Task. 

 

Since you are using a generic issue link to create the parent/child relationship, and the QA Task is not a Sub-task type issue, the sample rule I provided won't work. 

 

The sample rule you provided in your last response is not going to work either because the use of the branch is incorrect. When you use a branch you change the focus of the rule to the issues you select in the branching action. In your branch you are changing from the issue you actual want to change to the issue linked to it. You will need a different structure to your rule.

 

 

 

 

 

In (1) you would specify "QA Task".

 

In (2) you would specify "child", or whatever the text is for the other half of your parent/child generic link. In this step you are confirming that the newly created QA Task is linked to another issue with your parent/child link.

 

In (3) where I have "is bug child of" you would specify the same thing as in (2). In this step you are searching for the issue that is linked to the QA Task as its "parent".

 

In (4) you are confirming that you found exactly one issue linked to the QA Task as its parent.

 

 

 

 

 

In (5) you are copying the Status from the parent issue you found in the Lookup Issue action to the QA Task that triggered the rule.

 

 

 

You will have to type in the smart value, and then select it where it displays below what you typed in to insert it into the field instead of

the default "copy from" text.

 

Trudy Claspill
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 6, 2024

(Copying my previous responses into my Answer thread)

 

 

@Adrian Szubert 

 

There are a couple of problems with the rule you created and posted here:

 

 

 

In 1 and 2 you need to be specifying "Child" not "Parent". If you look at the parent issue in the Linked Issues section what text do you see as the heading above the linked QA Task issue? That is the text you need in 1 and 2.

 

Additionally 3 is entirely wrong. You should not have a Lookup Issues step there. Delete it. Review the step that i have in my rule at 5. You need to have a Transition Issue step there.

 

Trudy Claspill
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 6, 2024

Copying my previous responses into my Answer thread

I believe I made a mistake. 1 and 2 should indeed be Parent. Please change those back to Parent and let us see if the rule works then.

Trudy Claspill
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 6, 2024

@Adrian Szubert 

What is the status assigned to the parent status? Is there a status of the same name in the workflow if the QA Task?

Which transition do you want used for the QA Task in this rule?

Adrian Szubert July 7, 2024

@Trudy Claspill 

QA Task and Story are issue types assigned to the same workflow.

When QA TASK is created (via automation - Parent reaches status Ready in XXX), I want QA Task to be transitioned directly to THE SAME status of a Parent (there are four different READY IN XXX statuses in the workflow, based on the specific deploy branch).

image.pngimage.png

Parent (e.g. Story) reaches Ready in XXX -> it triggers automation to create QA Task (QA Task is a linked issue- Child).

QA Task is set to TODO, and then QA Tester must move it through the whole workflow. 

 

Adrian Szubert July 7, 2024

@Trudy Claspill 

I have it working - so the transition from TODO to Ready in was impossible  - that should follow the path. I created a direct connection between TODO and Ready in Majortest, and now I have it working.

However, that does not seem nice - giving the option to the Users of skipping some statuses and moving directly to Ready in (especially since I have 4 of those).

 

QUESTION! Is it possible to create a separate workflow path for QA Task, but mirror statuses from Story, and have automation "kicking in" every time?

Trudy Claspill
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 8, 2024

I am unclear about what you are asking with this question:

Is it possible to create a separate workflow path for QA Task, but mirror statuses from Story, and have automation "kicking in" every time?

Originally you asked only that when the QA Task was created it be immediately transitioned to the same status as the linked "parent" issue, which would be

the Parent reaches a certain status

...according to your original question.

It sounds like you are now asking for something different, which is to keep the QA Task status in synch with its linked "parent" issue. I'm interpretting that to mean you want the QA Task status updated every time the linked "parent" issue status is updated. Is that what you are now asking for? If so, that would be a separate automation rule then the one we'e been working on to get the QA Task into the same status as its "parent" when the QA Task is initially created.

 

If you want a workflow transition than can be executed only by the Automation for Jira user, you need to use this condition in the workflow transition:

  • Hide From User Condition (can only be triggered from a workflow function or from REST)

That will hide the transition from users in the UI while allowing the Automation Rule, with the rule Actor set to Automation for Jira, to make that transition.

Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 7, 2024

Hello @Adrian Szubert 

I notice you clicked the Accept Answer button on your own Answer. Did you get all the information you needed to resolve your requirement?

If my and Bill's responses helped you solve your requirement and you have no additional questions, please consider clicking the Accept Answer button on our answer thread also.

 

Adrian Szubert August 8, 2024

Hello @Trudy Claspill 

 

thank you, indeed. Also, set up for the rest ones. Your help and support were great.

Like Trudy Claspill likes this
0 votes
Adrian Szubert July 5, 2024

Hello @Trudy Claspill 

 

Thank you for such a warm welcome.

Just to answer your first question - when I created automation for that QA Task approach, I struggled a bit with issue status transitions (the same scenario - upon the QA Task being created, move it to a certain status in the workflow). I found one of the Atlassian Community answers (that was the top answer in this subject) that was pointing exactly to this limitation - JIRA automation cannot trigger another JIRA automation.

 

QA Task is a separate custom issue type we have introduced to log time and display just QA activities - anyway, business background does not matter here.

That's a generic link relation.

According to your message, Automation A, can trigger Automation B - but that never worked for me. It just looks like automation is not registering issue creation as a trigger and then it skips it - I have no particular example now except for the following audit log:

2024-07-05_18h49_07.png

As you can see, I had an automation rule triggered by the creation of the issue type "QA Task" - given your message, when Parent Story is set to Ready in XXX status, that creates QA Task. As the Issue type meets the condition, that should trigger Automation B to transition issue status. Every config change was done after a few trials per adjustment to automation - there were not even lines about no actions performed except for one, that I created manually (another issue type).

 

I have another automation that is triggered based on issue transition and works great (pic below), but the requested one must be triggered manually, and I would like to avoid hardcoding statuses into it (as below), but copy status of the linked Parent.
image.pngThe closes I got is below:
image.pngbut then it ends up with a lack of possibility to reach the destination status. We have some validators on the way, but QA Task is a full copy of Parent Story and manually I can easily transition that. They are in the same workflow.

 

Can it be that we have 4 different workflow paths after In progress?, the system just cannot clone the Parent status value. (that would be weird, as workflow is just one thing, not a separate one).

Trudy Claspill
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 5, 2024

 I found one of the Atlassian Community answers (that was the top answer in this subject) that was pointing exactly to this limitation - JIRA automation cannot trigger another JIRA automation.

Can you provide a link to that post/answer? I want to add a comment to it if it has incorrect information.

Please provide screen images that show the complete Automation Rule that you use to create the QA Task. 

Since you are using a generic issue link to create the parent/child relationship, and the QA Task is not a Sub-task type issue, the sample rule I provided won't work. 

The sample rule you provided in your last response is not going to work either because the use of the branch is incorrect. When you use a branch you change the focus of the rule to the issues you select in the branching action. In your branch you are changing from the issue you actual want to change to the issue linked to it. You will need a different structure to your rule.

Screenshot 2024-07-05 at 10.44.41 AM.png

 

In (1) you would specify "QA Task".

In (2) you would specify "child", or whatever the text is for the other half of your parent/child generic link. In this step you are confirming that the newly created QA Task is linked to another issue with your parent/child link.

In (3) where I have "is bug child of" you would specify the same thing as in (2). In this step you are searching for the issue that is linked to the QA Task as its "parent".

In (4) you are confirming that you found exactly one issue linked to the QA Task as its parent.

Screenshot 2024-07-05 at 10.48.45 AM.png

 

In (5) you are copying the Status from the parent issue you found in the Lookup Issue action to the QA Task that triggered the rule.

Screenshot 2024-07-05 at 10.49.50 AM.png

You will have to type in the smart value, and then select it where it displays below what you typed in to insert it into the field instead of the default "copy from" text.

Screenshot 2024-07-05 at 10.50.12 AM.png

Like Adrian Szubert likes this
Bill Sheboy
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 5, 2024

Hi @Adrian Szubert -- Welcome to the Atlassian Community!

Regarding the rule triggering information you note, this may be a matter of semantics where:

  1. a rule cannot directly start another rule executing (i.e., one rule cannot call another rule); instead...
  2. the actions performed by one rule can trigger another rule.

There are elaborate workarounds for #1 although I would advise using them sparingly.

Kind regards,
Bill

Like John Funk likes this
Trudy Claspill
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 6, 2024

@Adrian Szubert 

There are a couple of problems with the rule you created and posted here:

Screenshot 2024-07-06 at 10.08.30 AM.png

In 1 and 2 you need to be specifying "Child" not "Parent". If you look at the parent issue in the Linked Issues section what text do you see as the heading above the linked QA Task issue? That is the text you need in 1 and 2.

Additionally 3 is entirely wrong. You should not have a Lookup Issues step there. Delete it. Review the step that i have in my rule at 5. You need to have a Transition Issue step there.

Screenshot 2024-07-06 at 10.11.35 AM.pngScreenshot 2024-07-06 at 10.11.56 AM.png

Adrian Szubert July 6, 2024

Hi @Trudy Claspill hopefully you enjoy your Saturday. 

Indeed, I made some mistakes (the last step was certainly a mistake, on steps 2 & 3 I got a bit lost haha). 

Anyway, I provided the changes and automation runs! However no action is performed, as conditions are not meeting the criteria.

image.pngI wonder what may be causing this hmm
image.png

Trudy Claspill
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 6, 2024

I believe I made a mistake. 1 and 2 should indeed be Parent. Please change those back to Parent and let us see if the rule works then.

Adrian Szubert July 6, 2024

@Trudy Claspill running into following issues:
image.pngWorks if transitioned manually. 

Can it be workflow-related? As mentioned before, my workflow contains four different paths to transition from "In progress":

TODO / READY FOR DEV -> In progress->:

->Path 1: Awaiting Deployment to Sandbox 1

->Path 2: Awaiting Deployment to Sandbox 2

->Path 3: Awaiting Deployment to Sandbox 3

->Path 4: Awaiting Deployment to Sandbox 4

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events