Automation Rule fails with the error "you do not have the permission to comment on this issue"
Platform Notice: Data Center - This article applies to Atlassian products on the Data Center platform.
Note that this knowledge base article was created for the Data Center version of the product. Data Center knowledge base articles for non-Data Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
The error below is observed in the audit logs of an automation rule when the Comment on issue action is executed:
<Jira_User_Name>, you do not have the permission to comment on this issue.
The purpose of this article is to explain how to diagnose this error and fix it.
Environment
Jira Data Center on any version from 9.0.0.
Root Cause
Root Cause 1 - Lack of permissions due to the Project Permission Scheme
A possible cause is the fact that the Actor for the affected automation rule does not have permission to comment on the affected issue due to the Permission Scheme associated to the project.
Root Cause 2 - Lack of permissions due to properties added to specific statuses in the workflow configuration
Another possible cause is the fact that the Actor for the affected automation rule does not have permission to comment on the affected issue due to some properties used in the Workflow configuration which are preventing all of some users from commenting on issues that are in a specific status.
Diagnosis
Diagnosis for Root Cause 1
Follow the steps below to check if this root cause is relevant:
- Access an affected issue.
- Click on the 'Admin' drop-down menu on the issue context.
- Choose 'Permission helper'.
- Fill out the form as:
- User: <Actor for your Rule>
- Permission: "Add Comments"
- Click on submit
- If the test fails as illustrated below, then this root cause is relevant
Diagnosis for Root Cause 2
Follow the steps below to check if this root cause is relevant:
- Take note of the workflow status of the Jira issue that the rule failed to edit
- Edit the workflow associated to this issue and switch to the diagram view
- Click on the status and check it's properties
- If you see property keys related to issue editing, such as jira.permission.comment.user or jira.permission.comment.denied as illustrated in the 2 screenshots below, then this root cause is relevant:
- Example 1:
- Example 2:
- Example 1:
Solution
Ensure that the Rule Actor is granted the permission to add comments to the issue. Depending on the root cause identified in the Diagnosis section, the solution will consist in:
- Either adjusting the Permission Scheme configuration
- Or the Workflow Properties