Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How can I require a github pull request when transitioning state?

Kieran Pilkington
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 21, 2022

We have an "In Progress" column and a "Code Review" column. I would like to make it so that you cannot transition the ticket to Code Review without a github pull request being linked to on the ticket. Is there any way to do this?

1 answer

0 votes
Patrik Korovsky
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.
November 25, 2022

Hi @Kieran Pilkington

My answer may be unnecessarily complicated, but I would approach it this way:

  1. Create a new custom field and add it to your issue fields; in my example "Test Data" that can be edited by automation
  2. Add a validation to the transition from "In Progress" to "Code Review"
    Validation.png
  3. Create an automation rule that populates the "Test Data" field when a PR is made
    PR.png

If no PR has been performed, the field should be unpopulated and the transition should not be possible.

Note, I haven't tested this, but I believe it should work. There might be a problem with validating that the PR was done before the problem got to "in progress". It might be safer to set it up with a condition that compares it to a "custom number field" that is updated the same way (instead of text). This way even if it happens before it gets into such status it is possible to transition.

Suggest an answer

Log in or Sign up to answer