Forums

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

Jira Automation - Edit Issue Fields Error

Sunny Liao August 22, 2024

Hello Community,

I am in the process of setting up an automation rule in Jira and could use some assistance. Here is the rule I'm trying to configure:

  1. If an issue was updated 2 weeks ago: Send an email to the assignee and update each issues' field called "Email Sent" to 1.
  2. If an issue has not been updated for 4 weeks: Send a follow-up email.
    Screenshot 2024-08-23 135307.png

I've successfully set up the first part of the rule. However, I'm encountering an issue with the "Edit Issue Fields" action. Specifically, I am receiving the following error message:

This component may be incompatible. One of the following needs to be produced earlier in the rule by the trigger or with a 'for each' branch for this component to work: Issue.

Could anyone provide guidance on how to resolve this error or suggest a workaround? Your help would be greatly appreciated.

Thank you in advance for your support.

1 answer

1 vote
Trudy Claspill
Community Champion
August 22, 2024

Hello @Sunny Liao 

Welcome to the Atlassian community.

The problem is that you have created your branch based on Assignee, so the actions in the branch don't have a pointer to a specific issue to update.

Are you trying to send each Assignee one email listing all the relevant issues, or are you trying to send each Assignee one email for each issue?

Sunny Liao August 22, 2024

I am trying to send each assignee an email listing all the relevant issues assigned to them. For each of these issues, I will update the “Housekeeping Email Sent” field to 1. This will create a record indicating that the issue has been notified to the assignee.

In the second round, if an issue has not been updated for 4 weeks, we will send a follow-up email. At that point, we will filter the issues to include only those with the “Housekeeping Email Sent” field set to 1.

 

Trudy Claspill
Community Champion
August 22, 2024

Thank you for the clarification.

You need to, essentially, branch to each issue found in the Lookup Issues to update the issue.

However, you cannot create a branch within a branch.

One small change I would recommend is in your first Lookup add to the JQL the criteria Assignee is not empty. That will prevent the second branch from trying to execute for the unassigned issues.

I think one solution would be for you to add another branch in parallel to the Assignee branch you have currently. For this other branch, branch on the smart value for distinct key values in the first Lookup Issues results and have an action to update the Housekeeping Email Sent field.

Like Bill Sheboy likes this
Sunny Liao August 25, 2024

Screenshot 2024-08-26 092635.png
Thank you @Trudy Claspill 

I have tried to create another branch and set {{lookupIssues.key}} as the Smart value, however the edit issue is still having error. 

May I know why? and how to fix it?

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.
September 9, 2024

Hi @Sunny Liao 

Adding to the suggestions from Trudy...

You describe checking for updates to issues within a time frame, send only one email communication per assignee spanning their issues, and then update the issues.

There is no nested branching to support a scenario like this.  As Trudy described, your branch on the distinct assignee does not provide an issue for the Edit Issue action.

I can think of two ways to solve this:

  • Ignore the requirement to send only one email, as the trigger is the issue update and those are distinct.  Thus an assignee will get one email per issue.
  • Use two rules...

Kind regards,
Bill

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