If a rule isn’t behaving as expected, the following information can help you troubleshoot and resolve issues.

1. Check the audit log

Checking the audit log should be your first step when a rule is failing. When reviewing the audit log:

  • Check for any displayed errors. If there are errors, do they offer any suggestions or instructions on how to fix the problem?

  • Are all the relevant fields on the right screens in Jira?

  • Compare the edits in the audit log with the issue history tab on the issue page.

  • If there are no entries and you were expecting some, you either haven’t configured the trigger correctly, or the trigger has a filter on it which isn’t behaving as you expect.

2. Debugging smart-values

Use the Log action

The Log action adds values into the audit log, including smart values. This can be useful when testing complex smart-value functions.

Log message:

This should evaluate to 2: {{#=}}1 + 1{{/}}

Use debug

Using the Log action requires you to add an additional component to your rule. To avoid this, you can use the {{#debug}} function, e.g. {{#debug}}{{issue.fields.description}}{{/}}.

Surrounding any smart value with debug, allows the smart value to be processed as normal and also prints the value in the audit log to provide more contextual information.

{{#debug}}{{#=}}1 + 1{{/}}{{/}}

When this rule now executes, the audit log will contain:

Debug message

3. Make the testing easy & clean

  • Copy the rule and disable the original before testing. This allows you to revert to the original rule easily if you make changes.

  • Use the Manual trigger to execute a rule from an issue at any time.

  • Use the Scheduled trigger and click Run rule to trigger the rule for testing.

  • Use the smart value {{now}} to include the current time in your issue fields. This allows you to see when the edit was made and if the value changed.