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

Automation rule should send email based on lookup issues but it either sends duplicates or no emails

Abiy Kaltiso August 25, 2022

What I am trying to do

Trigger: Every weekday at 8:30am

Action: Lookup stale issues based on a JQL query

Then: Email the assignees of those issues with a list of their stale tickets

Expected result: assignees with stale tickets should each get 1 daily email at 8:30am with all of their stale tickets in a list

Actual results: assignees get duplicate emails.

or

If I uncheck the box "Run a JQL search and execute actions for each issue in the query” on the scheduled trigger step then I thought that would solve the problem but instead it ends up not sending any emails at all with the error, “Could not send email, the ‘To’ address field is empty. If you have referenced a field it may be empty.” in the audit logs

The JQL I have in the screenshots are just test issues. Actually query to find stale issues will be be based on last updated date. 

Screen Shot 2022-08-25 at 1.23.33 PM.pngScreen Shot 2022-08-25 at 1.23.45 PM.png

3 answers

0 votes
Edrick November 4, 2022

you need to create an action which create a variable and as the value of the variable add this {{#lookupIssues}}{{assignee.emailAddress}} {{/}} . Then use the created variable  on the to  for the email. image.png

francis.pierre-louis
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!
May 12, 2023

@Edrick did this actually work? And @Abiy Kaltiso did you ever find a solution. Im having the same issue.

Mauricio Heberle
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.
May 15, 2023

Did you try using the variable?

0 votes
Edrick November 4, 2022

im having the same issue, any more suggestions

0 votes
Mauricio Heberle
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 25, 2022

Try removing the Jql from trigger 

Abiy Kaltiso August 26, 2022

Hi Mauricio, as mentioned if I remove the JQL from the trigger then no emails are sent and I get the error in the audit logs, "Could not send email, the ‘To’ address field is empty. If you have referenced a field it may be empty.” 

Like francis.pierre-louis likes this
francis.pierre-louis
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!
May 12, 2023

Anyone resolve this?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events