Forums

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

Find linked issues of linked issue

Natasha Richardson July 30, 2024

I am trying to find the linked issues of a linked issue and check the status and then transition them.

I have a Manual trigger that closes an issue and then a branch to check the FOR Linked issue of type "blocks" and close any child related tickets on that linked issue. That linked issue also has linked issues of "relates to" type but I can't get to it to check. I can reach the Child tickets of the linked ticket but not the linked issues of that linked ticket. I have tried using the related issue condition for sub-tasks and linked issues.

Also open to other ways of achieving this. TIA.

Screenshot 2024-07-30 092314.png

2 answers

1 vote
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 30, 2024

Hi @Natasha Richardson -- Welcome to the Atlassian Community!

Rules do not support nested branching, and so a workaround for your scenario is:

  1. once inside of the branch on the linked issues of the trigger issue...
  2. use the {{issue.issuelinks}} smart value and list filtering / conditions to check the linked issues of those ones

Here are some references to help with those techniques:

Depending upon the criteria you need, this may be complicated to implement.  I recommend first testing without any issue updates, and instead just write to the audit log.  Once it is all working you could adjust the rule to perform updates.

Kind regards,
Bill

Natasha Richardson July 31, 2024

Thanks, Bill! So I ended up doing a lookup in the branch and I am getting to the linked issue that I want now per the log actions but then when I do the comparison of the smart-value, its still grabbing the first linked issue. Just wanted to see if you had any ideas here if not no worries. 

issue in linkedIssues("{{firstLevelLinkedIssueKey}}", "relates to")

Screenshot 2024-07-31 082931.png

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 31, 2024

Would you please post images of the create variable actions and of the audit log details showing the rule execution?  Thanks!

Natasha Richardson July 31, 2024

Certainly! Here it is:

firstLevelLinkedIssueKey.png

secondLevelLinkedIssueKey.pngsmartvalecondition.pnglog.png

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 31, 2024

First for those writes to the audit log, please add some labeling to confirm what we are observing.  For example:

firstLevelLinkedIssueKey: {{firstLevelLinkedIssueKey}}

 

Next, for more context please show images of the entire updated automation rule and of the entire audit log details for that rule execution.  Those will help distinguish which issues are being acted upon in the rule steps.

Natasha Richardson July 31, 2024

OK, sorry I thought that was what you needed. Yes 28312 is the firstLevelLinkedIssueKey and 28311 is the secondLevelLinkedKey so it's finding the correct issues but for whatever reason the smartvalue condition check is referencing 28312 when it should reference 28311 from the lookup. But I actually am thinking of going in another direction altogether because I think this is getting too complex. I am going to just link the issue I need to the issue I am running the manual automation against and then check the status from there. 

Like Bill Sheboy likes this
1 vote
Carla Ann Rowland
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 30, 2024

Looks like you need another branch  to check for related issue link -- it will probably be best to separate them the rules.  Your 1st rule takes the first level of children that are block. 

But to set the criteria again to look at the children of the linked tickets I think the logic cannot handle it.

I suggest: linked issue you just closed based on criteria above had a rule:

If linked issue is block by is closed then if sub-tasks exist then close them. If there is that allows this rule to be called by other automation then allow that to happen.

---

hope this helps.

Suggest an answer

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

Atlassian Community Events