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

When creating a child-issue from an issue, what automation trigger would I use?

Todd Thelin May 20, 2020

I have created an issue and assigned it to a developer. He then created a child-issue but this child-issue was not automatically assigned to him. Is there a way to automate child-issues? And more, is there a way to not include child issues in an automation script?

This should not be in Jira Service Desk. I cannot figure out how to move it.

2 answers

1 vote
Petter Gonçalves
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 21, 2020

Hello @Todd Thelin

Thank you for reaching out.

I'm not sure if I completely understood your request, but it seems you are looking for an automation rule to properly copy the assignee from parent to child issues when creating the child-issue. Is that correct?

Also, when you say "Child-issues", I believe you are talking about sub-tasks. Can you confirm it?

If I have properly understood your request, you can achieve that with the following steps:

  1. Navigate to your project > Project settings > Automation
  2. Create the following rule:
    Screen Shot 2020-05-21 at 18.47.24.png

This would be the background of the rule:

  • The rule is triggered when an issue is created
  • Using the "Issue fields condition", check if the issue created is a sub-task
  • Using the action "Edit issue fields", copy the assignee from parent to sub-task

Let us know if you have any questions.

Matthew September 21, 2020

@Petter Gonçalves thanks for this answer.

I am having issues attempting to replicate your solution because it doesn't appear that new sub-tasks are immediately associated with their parent task when created. The "When: Issue Created" trigger appears to fire before the association is made between sub-task and parent.

I've added a condition to your automation after the "If Issue Type equals Sub-task" rule to check if a Parent exists.

jira-automation.png

The "If Issue Type equals Sub-task" condition is satisfied, but the "Parent exists" condition fails.

jira-automation-results.png

Conversely, if I manually trigger this automation flow after the sub-task is created, the automation gets completed (and "Labels" value copied) successfully.

Is there any workaround for this? Maybe some way to trigger automation if a new parent link is added to an issue?

NOTE: I am using a NextGen board.

Petter Gonçalves
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 21, 2020

Hello @Matthew

Despite the error returned, could you please let us know why are you adding the condition "And: Parent exists"? What are you trying to achieve with this condition?

I ask this question because you already have the condition "If Issues equals Subtask" and a sub-task does not exist without a parent, so there is no point in keeping both conditions.

In other words, the condition "And: Parent exists" is redundantly checking the same setting as "If Issues equals Subtask" and possibly causing the error you are facing.

Please give us more details so we can better understand your goal.

j1823gs January 8, 2021

Conversely, if I manually trigger this automation flow after the sub-task is created, the automation gets completed (and "Labels" value copied) successfully.

Just commenting to indicate that this was my experience also - trying to trigger an automation on a sub-task to accessed the parent task properties would fail when it was automatically run, but succeeded when used as a manual automation.

As a workaround, I added the "Re-fetch issue data" action just prior to attempting to access the parent issue. This is a bit hacky, and I'm not sure it will be 100% reliable, but it appeared to do the trick.Screenshot 2021-01-08 at 14.26.53.png

Like Deleted user likes this
Deleted user August 15, 2021

thanks for sharing @j1823gs , the "re-fetch" made the trick for me as well.

0 votes
Todd Thelin September 28, 2020

We went away from Child Issues and we now sit with a classic project, The automation is still there, but we found better functionality with the classic project.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events