Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,465,088
Community Members
 
Community Events
176
Community Groups

Jira automation fails when adding DONE AND CANCELLED

I have an existing automation rule that will set the Story to DONE when all the Sub-Tasks are set to Done (When all sub-tasks are done → move parent to done).  Works perfect.  We now have administrators using the Cancelled status in their Sub-Tasks, so I need to adjust the automation rule.  

When: Issue is transitioned to Done

For Parent - Status does not equal Done.  And: Sub-tasks match "status = done". Related issues = Sub-tasks.  Condition = All match specified JQL.

Then: Transition the issue to Done.  

When I change And: Sub-tasks match "status = done OR status = cancelled" or "status = done AND status = cancelled" the rule fails to transition if the sub-tasks are set to cancelled.  If one sub-task is set to cancelled and one sub-task is set to done the rule fires appropriately.  I have tried many possible variations in changing\adjusting the "And:Sub-tasks match" field.  

Is there something specific to the Cancelled status?

Thank you for your help.

 

2 answers

1 accepted

2 votes
Answer accepted
Mark Segall Community Leader Dec 05, 2022

Hi @Bill Ewald - I would consider changing your sub-tasks match condition to status contains Done/Canceled or if you're using JQL status IN (Done,Canceled)

Validate query was successful.  Automation rule did not work when testing against two sub-tasks that were change to cancelled.  Not 100% sure I set the changes correctly.

Related issues - Sub-tasks

Condition - All match specified JQL

Matching JQL - status in (Cancelled, Done)

Mark Segall Community Leader Dec 05, 2022

Can you please share a screenshot of your rule and audit log?

Audit log just reads Config Changed.  No other details.

Jack Brickey Community Leader Dec 05, 2022

That tells me that the rule has not triggered since you changed the config. You need to transition a sub-task.

did you try the "statuscategory"?

Mark Segall Community Leader Dec 05, 2022

Ok - So your trigger is still only looking for when issues are transitioned to Done.  You'll need to include Cancelled in your trigger. 

Like Jack Brickey likes this

Yes I moved my two sub-tasks from Cancelled to In Progress and back to Cancelled.  The validate query returned 1200 results but the rule did not fire.  I am working on statuscategory now.

Attempted statuscategory= done AND statuscategory= cancelled.  It appears I only have TO DO, IN PROGRESS, and DONE.  When I run my JQL search:"project = ITOPS AND statusCategory = 3" it returns DONE and CANCELLED status results.

Did you see my last comment?  You'll need to update your trigger to include Cancelled.

Also - statusCategory is indiscriminate of individual statuses as it relates to the status colors you see on the screen (Gray = To Do, Blue = In Progress, Green = Done).  So assuming both your Done and Cancelled statuses are green, it would be statusCategory = Done

Mark I did see your last comment.  Trying to figure out where to add Cancelled.

Jack Brickey Community Leader Dec 05, 2022

please try this

2022-12-05_10-01-11.jpg

Like # people like this

That worked!  Thank you both!!

Like # people like this
1 vote
Jack Brickey Community Leader Dec 05, 2022

I would use this...

statuscategory = done

The reason being, if you ever add another "done" status it will still work.

I will adjust and test the rule.  Will return the findings to you.  Thank you!

Like Jack Brickey likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Site Admin
TAGS

Atlassian Community Events