Working with {{now.diff(issue.created).hours}}

Eran Roiter
Contributor
February 16, 2025

Hey all,

I'm trying to work with the {{now.diff(issue.created).hours}}, and as you can see in the picuters below, tickets i opened that are for sure more then hour old for some reason getting this msg 

The following issues did not match the condition:

Any ideas what I'm doing wrong ?

Thanks !!

image.pngimage.png

 

 

The following issues did not match the condition:

2 answers

2 accepted

3 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.
February 16, 2025

Hi @Eran Roiter 

The parameter order you show for the diff function (now before created) will produce a negative number: the issue was created before the current date / time.  And so the condition will fail.

Please try inverting the values:

{{issue.created.diff(now).hours}}

If that does not help, please post images of your complete rule and of the complete audit log details (with all areas expanded) to provide more context.

Kind regards,
Bill

Eran Roiter
Contributor
February 18, 2025

Thanks !!! it works :)  

Like Bill Sheboy likes this
0 votes
Answer accepted
Chimedtseren Otgongerel
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!
February 16, 2025

Hello, I can't activate my 8th check. It says pending and under review for many days. How can I activate it? Please help me.  

Dave Liao
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 16, 2025

@Chimedtseren Otgongerel - can you rephrase what you're asking? Are you also working on an Automation rule?

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