Forums

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

Smart value {{project.key}} does not work in Jira cloud automation

Anand Babu December 21, 2022

I have been trying to create a version every 10 days automatically.
To make the version name easily identifiable.
I am using release-{{project.key}}-date

But for some reason version name is not picking {{project.key}} smart value.
It used to pick it initially. Strange why it doesn't work now.

Any help will be appreciated



Screenshot 2022-12-21 at 5.22.57 PM.png

3 answers

1 accepted

0 votes
Answer accepted
Mayur Jadhav
Community Champion
December 21, 2022

Hello @Anand Babu ,

Welcome to the Atlassian Community!!

Please use {{issue.key}} instead of {{project.key}} in Automation rule.

For more details on Smart Value, you may have look on the below document.

Jira smart values - issues

 

 

Hope this information help!! Please hit the accept button.

 

Regards,
Mayur

Anand Babu December 21, 2022

Hi @Mayur Jadhav 

Thank you for the reply. Still no luck with {{issue.key}}.
Attaching screenshot for reference
Screenshot 2022-12-21 at 6.18.12 PM.png

Anand Babu December 29, 2022

Hi @Bill Sheboy 

Would you be able to provide any suggestion for this issue?

0 votes
Danny Bish
Contributor
November 2, 2023

You can use {{project.key}} as long as there is a trigger associated to something in the project.  A simple scheduled trigger will not pick up the project that it lives in.  This is an obvious bug, but that is the way it is unfortunately.

Mac McCardle
Contributor
July 8, 2024

My goodness, I've been wasting my time for ages on this bug :( 

0 votes
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.
December 29, 2022

Hi @Anand Babu 

Does your scheduled trigger have JQL (to gather issues) or is it just a schedule, without issues, to create a version daily?

Kind regards,
Bill

Anand Babu December 29, 2022

Hi @Bill Sheboy . 

Thank you for jumping in.

It's just a scheduled trigger without issues to create a version daily.

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.
December 29, 2022

I am puzzled how your rule worked as the {{project}} smart value is only available with the Project Created trigger, and not with scheduled and other triggers.  Although I did find an old test rule I wrote which does something similar, and it no longer works; apparently something has changed for rules.

The {{issue.project}} smart value is available whenever issues are available.  So you can still do what you want by having at least one issue to access {{issue.project.key}}

But to get that, you would need the project key anyway, so why not just hardcode it?

Anand Babu December 30, 2022

Hi @Bill Sheboy 

Thank you for your suggestion. 
I can hardcode it as the rule is not going to be global.

Like Bill Sheboy likes this

Suggest an answer

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

Atlassian Community Events