Getting a spinning wheel when clicking on the Edit button from the issue view screen
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
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
When clicking on the Edit button from the Jira View Issue screen, the page hangs and a spinning wheel is shown instead of the Edit Issue screen:
Environment
Jira Server / Data Center on 8.0.0 and any higher version.
Diagnosis
- Go to the configuration of the Edit Screen associated to the type of the issue where you see the problem (by going to Project Settings > Screens) and check the fields configured for that screen. If no field is configured for that screen (as shown in the screenshot below), then Root Cause 1 is relevant:
- Check if there is an announcement banner in ⚙ > System > Announcement banner
- if there any, and if the issue goes away after removing its content, then Root Cause 2 is relevant
- Enter plugin safe mode, and check if the issue is replicable
- If the issue goes away, then Root Cause 3 is relevant
- Generate a HAR file and also collect the output from the Browser Console logs while replicating the issue.
- If you see any Javascript error (you can find some examples below), then Root Cause 2, Root Cause 3 and Root Cause 4 might be relevant.
- Note that the examples are only example of Javascript errors. You might noticed different errors, which depends on how the problematic Javascript code was implemented (by 3rd party add-ons, script fields, or the announcement banner):
Example 1
VM2757:2 Uncaught TypeError: Cannot set properties of null (setting 'onchange') at eval (eval at globalEval (batch.js?locale=en-US:43:1085), <anonymous>:2:33) at eval (<anonymous>) at Function.globalEval (batch.js?locale=en-US:43:1085) at ye (batch.js?locale=en-US:69:1380) at u.fn.init.append (batch.js?locale=en-US:74:1099) at e.each.e.fn.<computed> [as append] (batch.js?agile_global_admin_condition=true&baseurl-check-resources=true&healthcheck-resources=true&jag=true&jaguser=true&jira.create.linked.issue=true&locale=en-US&richediton=true:4104:10231) at u.fn.init.<anonymous> (batch.js?locale=en-US:74:2187) at F (batch.js?locale=en-US:54:26034) at u.fn.init.html (batch.js?locale=en-US:74:1868) at e.each.e.fn.<computed> (batch.js?agile_global_admin_condition=true&baseurl-check-resources=true&healthcheck-resources=tru
Example 2
VM196:6 Uncaught TypeError: Cannot read properties of null (reading 'options') at filterPriorityfield (eval at globalEval (batch.js?locale=en-US:43:1085), <anonymous>:6:24) at eval (eval at globalEval (batch.js?locale=en-US:43:1085), <anonymous>:106:1) at eval (<anonymous>) at Function.globalEval (batch.js?locale=en-US:43:1085) at ye (batch.js?locale=en-US:69:1380) at u.fn.init.append (batch.js?locale=en-US:74:1099) at d.createFieldView (batch.js?agile_global_admin_condition=true&baseurl-check-resources=true&jag=true&jaguser=true&jira.create.linked.issue=true&locale=en-US&richediton=true:1937:136) at A (batch.js?locale=en-US:1208:258) at d.trigger (batch.js?locale=en-US:1206:488) at d._onModelEvent (batch.js?locale=en-US:1225:202) filterPriorityfield @ VM196:6
If you see an HTTP Request in the HAR returning with a "400 Bad Request" error, along with a Proxy server such as Microsoft IIS similarly to the example below, then Root Cause 5 is relevant
Request Method: GET Status Code: 400 Bad Request Server: Microsoft-HTTPAPI/2.0
- Open the HAR file and look for javascript code injected by a field description (from a Jira system field of a Custom Field)
Example 1 (javascript code injected by the custom field ID 14012):
\\"customfield_14012-description\\\"><b>This field is strictly for internal purpose. Please don't edit</b><br>\\n<script type=\\\"text/javascript\\\">\\n\\tvar assignee_field=document.getElementById(\\\"assignee-field\\\");\\n assignee_field.onchange = actOnAssigneeField ...
Example 2 (javascript code injected by the priority field):
<div class=\\\"description\\\" id=\\\"priority-description\\\"><script type=\\\"text/javascript\\\">\\n\\n\\nfunction filterPriorityfield()\\n{\\nvar x = document.getElementById('priority');\\n\\n//alert(x.options.length);\\nfor ( var i = 0; i < x.options.length; i++) \\n{\\n\\t\\t\\t\\t //alert(i+\\\":\\\"+x.options[i].value);\\n \\n\\n switch(x.options[i].value) \\n {\\n \\n \\n \\n \\n \\n case \\\"6\\\":\\n // alert(\\\"Deleting:\\\"+x.options[i].text);\\n ...
- If you find Javascript code injected by at least 1 field, try to remove it for each field 1 by 1, by following the steps below:
- Go Project Settings > Fields and click on on the Pencil icon on the right
- Scroll down to the field, edit it, and delete the content of its description
- Go Project Settings > Fields and click on on the Pencil icon on the right
- If the issue goes away after you removed the javascript code associated to a field, then Root Cause 4 is relevant
- If you see any Javascript error (you can find some examples below), then Root Cause 2, Root Cause 3 and Root Cause 4 might be relevant.
Cause
Root Cause 1 - Known Jira Bug
If no field is associated to the Edit Issue screen, then you will run into the bug listed below: the Edit Issue Screen will not load and you will get a spinning wheel:
JRASERVER-72779 - Getting issue details... STATUS
Root Cause 2 - Javascript issue in the announcement banner
The Announcement banner can be configured with Javascript in its description, which will be executed whenever any Jira page is opened. If the script is invalid, it might impact the ability to load the Edit Issue screen
Root Cause 3 - 3rd party add-on issue
Some 3rd party add-on might inject Javascript code that is not working properly with Jira. As a result, some Jira functionalities such as viewing the Edit Issue screen might be impacted.
If entering plugin safe mode fixed the issue, then you can identify which add-on caused the issue by exiting plugin safe mode, and then disabling each add-on 1 by 1 until the issue goes away.
One example of 3rd party add-on that was known to cause this issue is the Structure add-on (the versions 6.0 and 6.0.1 were affected by this issue, but the issue got fixed in recent versions of this add-on).
Root Cause 4 - Scripted field issue
Any field (system field or custom field) can be configured with Javascript in its description, which will be executed whenever the field is loaded (via a Jira issue screen). If the script is invalid, it might impact the ability to load the Edit Issue screen
Root Cause 5 - Proxy Server configuration issue
The Microsoft IIS proxy server is known to prevent Jira pages from being successfully loaded, especially if there is a URL size limit in its configuration. We have seen situation where such limit can impact the loading of the Edit Issue screen. For more information about this issue, you can refer to the KB article Pages not displaying properly when Jira Server is integrated with IIS.
Solution
Root Cause 1
Make sure that there is at least 1 field associated to the Edit Issue screen.
Root Cause 2
Remove the Javascript code from the announcement banner.
Root Cause 3
Disable the problematic 3rd party add-on and reach out to the add-on support team for further assistance.
Root Cause 4
Remove the Javascript code from the description of the problematic field.
Root Cause 5
Increase the URL size limit in the IIS proxy configuration, as explained in the KB article Pages not displaying properly when Jira Server is integrated with IIS.