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

Automation - Ticket to remain 'In Progress' when a draft PR is opened instead of transitioning

Edited

We have 2 columns on sprint board which are 'In Progress' and 'PR Open'. I have automation setup so that when a PR is opened, the ticket automatically transitions to 'PR Open' status and column.

When a draft PR is open, I want the ticket to remain 'In Progress' but this isn't happening, what am I doing wrong? I thought adding the check on the pull request state would work, but it doesn't. I've tried 'DRAFT' and 'Draft' to identify if it's an issue with the casing but it's not.

I'm trying to work around the lack of functionality which would be fixed by https://jira.atlassian.com/browse/JRACLOUD-72888, which we have been waiting years forScreenshot 2023-09-26 at 08.52.54.pngScreenshot 2023-09-26 at 08.53.12.png

3 answers

Thanks to the above I have identified a solution which works:

Screenshot 2023-09-27 at 12.42.27.png

Hmmm seems to have caused another issue...now when the pull request is transitioned from draft to open, the ticket no longer transitions from 'In Progress' to 'PR Open'...

I looked into this, and haven't found an available development variable to check the transition from draft to open (ready to review) state. But your solution is more than half-way there for me!

Like Kara Hopkins likes this
0 votes
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.
Sep 26, 2023

Hi @Kara Hopkins 

What if after the trigger, you write to the audit log the value of {{pullRequest.state}} to confirm the value?  That may help you identify what needs to be tested in the condition.

I wonder if that is an enumeration, and there is a lower attribute that could be checked.

Kind regards,
Bill

Thanks! I tried that and it looks like the case for 'DRAFT' is actually 'draft' so I've updated my automation rule again and hope this works next time the rule is run.

Like Bill Sheboy 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.
Sep 27, 2023

Well done, and thanks for posting that in the open suggestion as well!  That will benefit the community...and perhaps Atlassian will update the documentation to match what you found for the additional value in that field :^)

I've had to disable it unfortunately...it's had the unintended consequence of preventing any tickets with a true open PR from transitioning to 'PR Open' status when they are no longer in draft and these tickets are now remaining 'In Progress'.

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.
Sep 27, 2023

I wonder...

If you map out the flow to confirm the states and your processing timeline, could you capture when draft occurred in the issue (e.g., in a custom field, label, or entity property), and then either modify this rule (or use and additional one) to handle this case.

Thanks for your suggestion, I'm not really sure what to do and would rather not have to implement such a workaround for functionality which should be available. I think i'll just have to wait X many more years for https://jira.atlassian.com/browse/JRACLOUD-72888,!!

Like Bill Sheboy likes this
0 votes
Bert van Dijk _TMC_nl_
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.
Sep 26, 2023

Hi @Kara Hopkins ,

 

What if you use the "Does not contain" option instead of the "does not equal" option in the if statement?

 

Kind regards,

Bert

Thanks, I tried but it hasn't worked either. The status has still been updated to PR Open.Screenshot 2023-09-26 at 15.43.18.png

Suggest an answer

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

Atlassian Community Events