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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,556,741
Community Members
 
Community Events
184
Community Groups

IF condition does not find labels that are inserted on trigger issue

Edited

Hello,

Can someone help me understand why the following rule structure is not matching the IF condition for existing labels, when the trigger issue is adding the labels (as created from smart variables)?

1. Description: where regex extracts values after strings, such as New Trunks: and assigns to variable {{newTrunks}}

2. Edit issue drops those smart variables as Labels on the trigger issue. Labels are same as variables, in this case "newTrunks"

3. Issue shows label "newTrunks" after created.

4. IF condition: If label contains "newTrunks", then create a ticket. However, each run automation gives the message:

IF BLOCK
The following issues did not match the condition:
JOF-365
rule.pngticket.png
What am I missing here??
Thanks!

1 answer

1 accepted

2 votes
Answer accepted
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.
Mar 28, 2023

Hi @Jason M_ 

I am not quite following what you are trying to test...is it:

  • you want to check for a label value named "newTrunks", or
  • you want to check for a label matching the contents of the created variable {{newTrunks}}

 

And one more thing...When using basic conditions, the rule only continues if the test passes.  If instead you have multiple possible conditions, you may want to use the if/else structure, such as the following:

  • if/else condition
    • some condition test...
    • some action...
  • else/if
    • some other condition test...
    • some action...
  • else
    • some action

 

Kind regards,
Bill

Hi Bill,

 

Thanks for your response, to clarify I'm looking to match the contents of the created variable {{newTrunks}}, which equals the string "newTrunks", and that is added to the label field. 

From my screenshot of the rule above, that label field is updated in the component right before the If:matches condition that is failing. 

I can see the label field is updated with the word "newTrunks" in the trigger issue, yet the If:matches condition still fails to find the label.

I do know the basic condition will fail the remainder of the rule, and am using if/else components to get around that...but here I'm focused on why the condition is not finding the label.

Thanks!
Jason

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.
Mar 28, 2023

Gotcha, and thanks for clarifying.

When a rule triggers with an issue, the data remains in the as-triggered state even when issues are written out to the cloud/server.  When you want to refresh after an edit, add a Re-fetch action before proceeding.

This works for rules with a simple flow...branches that could be on more than one issue have a different behavior.  I cannot tell from your rule image excerpt if that applies to your situation.

Like Jason M. likes this

Awesome, that did the trick! Thanks for the explanation as well, much appreciated!

Like Bill Sheboy likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events