Forums

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

Automation rule to calculate Start and end based on earliest start and latest end from linked issues

yeswanth Reddy August 12, 2024

 

 

Hi all,

 I have create an automation  rule to calculate Start and end time for an issue  based on the earliest start and latest end from linked issues but look up issue isn't working can anyone please help me with this.Screenshot 2024-08-13 080234.pngScreenshot 2024-08-13 080504.png

2 answers

1 vote
Trudy Claspill
Community Champion
August 12, 2024

Hello @yeswanth Reddy 

Welcome to the Atlassian community.

It does not appear that you have provided the complete audit log entry for the rule. Can you provide that?

I can identify one problem from what you've provided.

In the Lookup Issues action you have referenced {{triggerIssues. You have used a plural when it should be singular.

Additionally using that smart value by itself is not going to be valid JQL syntax. I suspect your audit log includes an error message about that JQL statement.

Another possible problem is your branch to Parent. Why are you shifting the focus to the parent of the issue that triggered the rule?

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.
August 13, 2024

Hi @yeswanth Reddy -- Welcome to the Atlassian Community!

As Trudy describes, the JQL for your Lookup Issues actions is invalid, and...

Your rule seems to focus on specific link types (e.g., Blocks, Cloners, etc.) but the use of the links when creating your JQL does not check this.  As a result, issues with other link types will be returned.

 

To solve this, you could invert your approach, and use the JQL function linkedIssues() to check by the types : https://support.atlassian.com/jira-software-cloud/docs/jql-functions/#linkedIssues--

For example:

issue IN linkedIssues( {{triggerIssue.key}}, "Blocks", "Cloners", "Duplicate", "Post-Incident Reviews", "Problem/Incident", "Relates to" )

Please adjust this to match your specific link types needed, and then test the query with an example issue to confirm it returns what you expected.

 

Kind regards,
Bill

Like # people like this
yeswanth Reddy August 13, 2024

Thankyou, @Trudy Claspill  and @Bill Sheboy  for the response i will  modify and try the same and keep you informed if it helped.

yeswanth Reddy August 13, 2024

Screenshot 2024-08-14 074047.png

yeswanth Reddy August 13, 2024

i haven't got error in jql in audit log

 

Trudy Claspill
Community Champion
August 13, 2024

Well that is good news.

But I see that it also says No Actions Performed. Is that what you expected?

Does issue D1-45 have a Parent? It seems like the Log actions in your branch were not executed, which would be an indication that the trigger issue doesn't have a parent issue.

Dick
Community Champion
August 14, 2024

We should include the check if parent link is not empty in the JQL to know for sure that  the automation is capable of branching for the parent. Now we don't have that check and we are misled by the intermediate loggings of stuff that has nothing to do with the branched issue. 

 

0 votes
Dick
Community Champion
August 13, 2024

Hi,

I think you have a typo in the second lookupIssues block:

triggerissues.issuelink.key   

There is only one triggerissue.

yeswanth Reddy August 13, 2024

hi @Dick 

thankyou for the response.I have tried it but it didn't worked. 

Suggest an answer

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

Atlassian Community Events