Display Epic completion percentage on Jira Dashboard

Bryan Urias
Contributor
June 12, 2024

Hello everyone,

I have followed the steps outlined in Atlassian's article Display Epic completion percentage on Jira Dashboard to set up a custom field and automation rule for calculating epic completion percentages in our Jira Cloud instance, but I am unable to get the automation to work correctly, and accurately update the Epic Completion values. 

I've added two different "Epic Completions" to verify it wasn't due to "read-only" attributes from my original text custom field. 

Any insight on resolving based on the article's instructions and not a third-party application would be greatly appreciated! :) 

 

 

Epic Completion - Automation.jpgEpic Completion - Correct Screen.jpgEpic Completion Custom Field.jpg

2 answers

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.
June 13, 2024

Hi @Bryan Urias 

In my opinion, that Atlassian-written article is not super helpful at solving this scenario...particularly because it has some hidden assumptions and is quite inefficient.

Be that as it may...

If we assume it works, there may be a problem with one of the rule actions or the processing.  Please review:

  • each of your rule steps to confirm they match the article
  • post an image of the final, Edit Issue action as something seems incorrect in the image you show
  • confirm the case (i.e., capitalization) of the variables exactly match their use later in the rule, as smart values are case-sensitive
  • confirm the created variables use the asNumber function to convert the text to numbers
  • post an image of the audit log details to confirm the steps work as you expect...and if not
  • write the values to the audit log to check the progress. 
    • Specifically, I recommend writing each created variable to the audit log after they are created to confirm they contain what you expect.

 

Or as an alternative, try this rule:

  • trigger: issue transitioned
  • condition: issue type is one of Story, Task, Bug... (i.e., whichever types you assign to epics)
  • condition: parent is not empty
  • action: lookup issues with JQL of
parent = {{triggerIssue.parent.key}}
  • branch: to parent
    • action: edit issue to set your field to this:
{{#=}}ROUND( ( 0{{#lookupIssues}}{{#if(equals(status.statusCategory.name,"Done"))}}+1{{/}}{{/}} ) / {{lookupIssues.size|0}} * 100, 0){{/}}

That percentage would be by issue count.

 

If you instead wanted the percentage by story points, please use this:

{{#=}}ROUND( ( 0{{#lookupIssues}}{{#if(equals(status.statusCategory.name,"Done"))}}+{{Story points|0}}{{/}}{{/}} ) / {{lookupIssues.Story points.sum|0}} * 100, 0){{/}}

 

Both round to whole numbers, so please adjust as needed.

 

Kind regards,
Bill

0 votes
Danut M _StonikByte_
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
June 12, 2024

Hi @Bryan Urias

This seems complicated and requires a lot of work. 

Just be aware that this can easily done with the Pivot Table & Pivot Chart gadget offered by our Great Gadgets app, without any manual work and complicated settings like the ones in that article!

image.png

You just have to configure the gadget with a JQL that returns the issues from your epics: parentEpic IN (DEMO-1, DEMO-2), display the pivot table by Status Category and Epic Link fields and calculate by percentage of rows. And the table will be displayed on your dashboard, showing the data in real-time.

Hope this helps.

Danut   

Bryan Urias
Contributor
June 13, 2024

Hello Danut,

Thanks for your reply! While the recommended third-party application does what I am looking for, I am trying to set the same thing up with Atlassian's guide + automation, but seem to encounter an error along the way. Have an awesome day!

Best regards,

Bryan

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