Details
-
Bug
-
Resolution: Obsolete
-
Low
-
6.4.13
-
None
-
6.04
-
Description
Summary
Roles used in a workflow condition "User Is In Any Role" do not show up when checking where the role is used. If the role is deleted the Conditions that used it are broken and cannot be edited.
Environment
Verified in JIRA 6.4.13.
This bug does not occur in JIRA 7.0+ because the "User Is In Any Role" condition has been removed.
Steps to Reproduce
- Create a new role called "Bugtest" at Administration > System > Roles
- Create a new project, a new workflow, and make the project use this workflow.
- In the new workflow, go to a transition and click "Add condition"
- Select the "User Is In Project Role" and click "Add".
- For "Project Role" select the "Bugtest" role.
- Back at Administration > System > Roles click "View Usage" for the "Bugtest" role. The new workflow will be shown in the list of uses of this role.
- Edit the workflow, edit the transition, remove the condition.
- Add a condition using "User Is In Any Role" and add two roles (the "Bugtest" role and any other one)
- Publish the changes to the workflow.
- View usage, the workflow won't show
Expected Results
View usage for the "Bugtest" role should show the workflow that references it in the Condition.
Attempting to delete the role should warn that it is used in a project and workflow.
Actual Results
The workflow does not appear in the list of workflows using this role and an incorrect message is shown: "This project role is not associated with any notification schemes, permission schemes, issue security schemes or workflows."
The role can be deleted, JIRA does not warn that this role is used by a project and a workflow. If it is deleted it is removed from the workflow Condition.
After deleting the role, attempting to edit the Condition that was using it results in an exception and the Condition cannot be edited.
2016-06-10 15:37:41,681 http-bio-8583-exec-14 uri:/djira/secure/admin/views/wor...ansitiondescriptorparams.jsp username:admin ERROR admin 937x1334x1 1g1myj6 127.0.0.1 /secure/admin/workflows/EditWorkflowTransitionConditionParams!default.jspa [webwork.util.ValueStack] query="/descriptorHtml" {[id="null" type="5" values=""]} {[id="descriptorHtml" type="8" values=""]} java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ... at webwork.util.ValueStack.findValue(ValueStack.java:216) at webwork.view.taglib.WebWorkBodyTagSupport.findValue(WebWorkBodyTagSupport.java:62) at webwork.view.taglib.BasicPropertyTag.doStartTag(BasicPropertyTag.java:54) at org.apache.jsp.secure.admin.views.workflow.editworkflowtransitiondescriptorparams_jsp._jspx_meth_ww_005fproperty_005f5(editworkflowtransitiondescriptorparams_jsp.java:1292) ... Caused by: java.lang.NullPointerException at com.googlecode.jsu.util.WorkflowUtils.getStringRole(WorkflowUtils.java:1112)
Workaround
No workaround has been identified at this time. The solution is to upgrade to JIRA 7.