Getting the error "Snap! You can't view this page" when trying to configure Service Management project settings

Still need help?

The Atlassian Community is here for you.

Ask the community

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 trying to configure settings specific to Jira Service Management (JSM) projects such as SLAs, Portal Settings, Customer Notifications, the setting page can't be opened and the error "Snap! You can't view this page" is displayed in the UI:

Another possible symptom is the fact that, when accessing settings specific to JSM, the page is blank, but the error "Snap! You can't view this page" is displayed on the browser tab instead:


Environment

Jira Service Management (JSM) Server/Data Center on any version from 3.0.0.

Cause

Conditions required for a user to view settings specific to JSM projects

For any Jira user to be able to configure settings specific to JSM projects, this user needs to verify all of the conditions listed below:

  • Condition 1:
    • This user needs to be granted the Administer Projects permission in the permission scheme associated to the project
  • Condition 2:
    • This user needs to be granted the Service Desk Agent permission in the permission scheme associated to the project
  • Condition 3:
    • This user needs to be granted Jira Service Management (JSM) application access via a JSM license
    • (warning) Note that any other Jira license (Jira Core, Jira Software) won't help. Only the JSM license will allow the user to modify JSM settings

If Condition 1 is not met, then this user will not be able to access the Project Settings page at all.

If Condition 1 is met, but either Condition 2 or Condition 3 is not met, then the user will get the "Snap! You can't view this page" error.

Please note that by default, in any JSM project the Administrator and the Service Desk Team project roles are automatically granted with the Service Desk Agent permission, as shown in the screenshot below:

So "normally", being part of either project role is enough to be granted this permission. However, if the permission scheme associated to the JSM project was customized, then it is possible that these roles have been removed from the Service Desk Agent permission. In such case, adding users to either project role will no longer allow them to access the JSM project settings.

Please note that it is also required that the Jira application is configured with a JSM license that is not expired, and that can accommodate all the Jira users which were granted with the JSM application access. For example, it is possible that the JSM license was bought for 50 users, but that 60 users were granted JSM application access. In such case, 10 of these users will get the "Snap! You can't view this page" error, since there is not enough JSM licenses for all the 60 users.

List of known root causes for the "Snap! You can't view this page" error

  • Root Cause 1 - The impacted user was not granted the Service Desk Agent permission in the JSM project
  • Root Cause 2 - The impacted user was not granted JSM application access
  • Root Cause 3 - The impacted user was granted JSM application access but all the JSM licenses are already taken
  • Root Cause 4 - The JSM application is missing a license or the license has expired
  • Root Cause 5 - The JSM project has some data corruption issue
  • Root Cause 6 - JSM is running on a version lower than 4.19.0, and we are running into the bug JSDSERVER-11964 - Getting issue details... STATUS
  • Root Cause 7 - A backup from a Jira/JSM Cloud instance was imported into a Jira/JSM Server/Data Center instance, and we are running into the bug JSDSERVER-6539 - Getting issue details... STATUS

Diagnosis

Diagnosis for Root Cause 1

  • Go to ⚙ > System > Permission Helper
  • Select the affected user
  • Enter any issue key from the JSM project
  • Select the Service Desk Agent permission
  • Click on the Submit button
  • If you see that the user is not granted the Service Desk Agent permission as shown in the screenshot below, then this root cause is relevant:

Diagnosis for Root Cause 2

  • Log in as a Jira System Administrator
  • Go to the page ⚙ > User Management > Users
  • Search for the impacted user
  • Check for the Applications column. If you don't see the Jira Service Management application listed as shown below, then this root cause is relevant:

Diagnosis for Root Cause 3

  • Log in as a Jira System Administrator
  • Go to the page ⚙ > Applications > Version & Licenses
  • Check the number of users provided by the license applied to the JSM application, and compare with the number of used licenses
  • If you see that the number of used license is higher than the actual license applied to the JSM application, then this root cause is relevant

Diagnosis for Root Cause 4

  • Log in as a Jira System Administrator
  • Go to the page ⚙ > Applications > Version & Licenses
  • Take a look at the JSM application
  • If the JSM application is missing a license, or if it has a license but the license has expired, then this root cause is relevant

Diagnosis for Root Cause 5

We have seen some situation where the impacted user met all the required condition to access the JSM project settings (the user had a license and the right permission), however the error still occurred. It is possible that, for some reason, the JSM project has some corrupted data. The exact reason for the corrupted data is unclear, but one way to verify it is to check the Jira application logs and look for the error below:

Technical details
Log's referral number: ac49db5b-c81a-4b86-b5e9-4aa9130fc2e7
Cause
Referer URL: http://10.60.5.112:6704/SDS-11198/secure/BrowseProjects.jspa?selectedCategory=all&selectedProjectType=service_desk
java.lang.RuntimeException: This is a Service Desk project, but we were unable to load the Service Desk project context. It may be possible to fix this error by converting this project to a different project type, and then converting it back to Service Desk.
java.lang.RuntimeException: This is a Service Desk project, but we were unable to load the Service Desk project context. It may be possible to fix this error by converting this project to a different project type, and then converting it back to Service Desk.
    at com.atlassian.servicedesk.project.internal.web.sidebar.ServiceDeskSidebarContentRendererImpl.render(ServiceDeskSidebarContentRendererImpl.java:83) [?:?]
    at com.atlassian.jira.projects.sidebar.ProjectSidebarRendererImpl.render(ProjectSidebarRendererImpl.java:81) [?:?]

If the error below is found at the exact time when the impact user was trying to access any JSM setting in the project, and then root cause might be relevant.

For more information about this root cause, you can refer to the KB article ServiceDesk, Existing Project Fails To Load, 500 error, RuntimeException.

Diagnosis for Root Cause 6

Check the Jira application logs and:

  • look for the ERROR message the START time of the DateTimeRange (XXXXXXXX) must be less than or equal to the STOP time (XXXXXXX)
  • make sure that the end point /rest/plugins/applications/1.0/installed/jira-servicedesk/license is also part of the ERROR
  • lastly, check if this ERROR is thrown shortly after the message Startup has failed with an unexpected problem. It is unsafe to proceed, and shortly before the message [atlassian.servicedesk.lifecycle] We are now in an indeterminable state.

You can find below a snippet of Jira logs which meet all the conditions described above:

2022-09-07 10:31:09,182-0700 JIRA-EventThread-15 INFO XXXXX 631x396x2 1vxd0ky 127.0.0.1 /rest/plugins/applications/1.0/installed/jira-servicedesk/license [atlassian.servicedesk.lifecycle] Startup has failed with an unexpected problem. It is unsafe to proceed.
2022-09-07 10:31:09,182-0700 JIRA-EventThread-15 ERROR XXXXX 631x396x2 1vxd0ky 127.0.0.1 /rest/plugins/applications/1.0/installed/jira-servicedesk/license [c.a.s.b.lifecycle.server.ServerPluginLifeCycle] com.atlassian.servicedesk.internal.sla.metric.DateTimeRange - the START time of the DateTimeRange (2022-08-09T05:35:35.273Z) must be less than or equal to the STOP time (2022-08-09T05:34:03.397Z)
com.atlassian.servicedesk.internal.sla.metric.DateTimeRangeException: com.atlassian.servicedesk.internal.sla.metric.DateTimeRange - the START time of the DateTimeRange (2022-08-09T05:35:35.273Z) must be less than or equal to the STOP time (2022-08-09T05:34:03.397Z)
	...
2022-09-07 10:31:09,184-0700 JIRA-EventThread-15 INFO XXXXX 631x396x2 1vxd0ky 127.0.0.1 /rest/plugins/applications/1.0/installed/jira-servicedesk/license [atlassian.servicedesk.lifecycle] We are now in an indeterminable state.

If the Jira Service Management application is on any version below 4.19.0, and if Jira application logs look like the snippet above, then the JSM application is impacted by the bug JSDSERVER-11964 - Getting issue details... STATUS , which is known to put the JSM application into an invalid state and not only cause the "Snap" error on JSM project setting pages, but also cause the 403 error when accessing the Customer Portal.

(warning) It is important to make sure that the end point /rest/plugins/applications/1.0/installed/jira-servicedesk/license is also part of the SLA ERROR. If you see the same SLA error in the logs but without the license end point, then this error is not relevant to the JSM issue covered in this KB article.

Diagnosis for Root Cause 7

The diagnostic steps are the same as the ones described in the bug JSDSERVER-6539 - Getting issue details... STATUS .

The steps are copied below:

  1. Connect to the Jira database
  2. Check the max ID value from the customfieldvalue by running the following query (query 1):

    select max(ID) from customfieldvalue;
  3. Check the sequence ID from the sequence_value_item table for the Custom Field Value by running the following query (query 2):

    select seq_id from "sequence_value_item" where seq_name = 'CustomFieldValue';
  4. Check if the max ID from the customfieldvalue table is higher than the seq_id from the sequence_value_item in the Jira database (although in a normal situation, it should be lower). If that's the case, then this Root Cause is relevant, and you can move on to the Solution for Root Cause 7 section


Solution

Solution for Root Cause 1

Make sure that the user is granted the Service Desk Agent permission in the JSM project. For more information, please refer to the documentation about managing project permissions.

Solution for Root Cause 2

Make sure that the impacted user is granted JSM application access, as illustrated in the example below:

Solution for Root Cause 3

Make sure that the number of used JSM licenses is not higher than the number of users allowed by the license associated to JSM. You can either purchase a license for more users, or remove the JSM license from Jira users who no longer need it. For more information, please refer to the documentation manage group access to applications.

Solution for Root Cause 4

Make sure that the JSM application is configured with a license that has not expired.

Solution for Root Cause 5

The best option is to create a fresh new JSM project.

Or, if you need to keep the existing corrupted JSM project, what you can do is change the type of the project to something else (Business or Software), and then change it back to a Service project. For more information about this workaround, please refer to the KB article ServiceDesk, Existing Project Fails To Load, 500 error, RuntimeException.

Solution for Root Cause 6

The safest, cleanest and most reliable option is to update JSM to the version that has the fix (JSM 4.19.0 or any higher version).

If upgrading is not an option for now, then you can refer to the workaround described in the bug JSDSERVER-11964 - Getting issue details... STATUS .

Solution for Root Cause 7

The resolution steps are the same as the ones mentioned in the bug JSDSERVER-6539 - Getting issue details... STATUS

The steps are copied below:

  1. Stop the Jira application
  2.  Backup your Jira database, so that you can revert back the changes if anything goes wrong
  3. Connect to the Jira database
  4. Check the max ID value from the customfieldvalue by running the following query (query 1):

    select max(ID) from customfieldvalue;
  5. Check the Sequence ID from the sequence_value_item table for the Custom Field Value by running the following query (query 2):

    select seq_id from "sequence_value_item" where seq_name = 'CustomFieldValue';
  6. Verify that the Max ID value is higher than the Sequence ID
  7. Update the sequence_value_item table by running the following query (query 3) and replacing xxxxx with the value from the results of query 1 + 1 (for example, if the result from query 1 was 1000, update xxxxx using 1001):

    update "sequence_value_item" set seq_id = xxxxx where seq_name = 'CustomFieldValue';
  8. Start the Jira application



Last modified on Jun 20, 2023

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.