UI: Update error message when insufficient permissions for workspace
See original GitHub issueI got “Error retrieving workspace” when clicking on a workspace within the web UI.
Steps to reproduce
- Deploy TRE (commit
735ae301df542059015a360ffa0c18b0236ffec2
) - Deploy base workspace
- Navigate to UI and click on the deployed workspace
Looking in the console logs, I see
useAuthApiCall.ts:44
No account object found, please refresh.
(anonymous) @ useAuthApiCall.ts:44
NotificationPanel.tsx:47
LOADING ALL OPERATIONS...
(anonymous) @ NotificationPanel.tsx:47
/api//workspaces/14a5ac49-c1bb-49b3-9d54-21bdad12b7f4/workspace-services:1
Failed to load resource: the server responded with a status of 403 (Forbidden)
useAuthApiCall.ts:104
Error calling /workspaces/14a5ac49-c1bb-49b3-9d54-21bdad12b7f4/workspace-services: 403 - Forbidden
(anonymous) @ useAuthApiCall.ts:104
NotificationPanel.tsx:56
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'workspaceServices')
at NotificationPanel.tsx:56:130
at u (runtime.js:63:40)
at Generator._invoke (runtime.js:294:22)
at Generator.next (runtime.js:119:21)
at l (asyncToGenerator.js:3:20)
at a (asyncToGenerator.js:25:9)
App.tsx:110
Workspace set Object
setWorkspace @ App.tsx:110
App.tsx:108
Workspace roles undefined
setRoles @ App.tsx:108
/api/workspaces/14a5ac49-c1bb-49b3-9d54-21bdad12b7f4/workspace-services:1
Failed to load resource: the server responded with a status of 403 (Forbidden)
useAuthApiCall.ts:104
Error calling workspaces/14a5ac49-c1bb-49b3-9d54-21bdad12b7f4/workspace-services: 403 - Forbidden
(anonymous) @ useAuthApiCall.ts:104
VM2996 react_devtools_backend.js:4026
Workspace roles Array(0)
overrideMethod @ VM2996 react_devtools_backend.js:4026
VM2996 react_devtools_backend.js:4026
Workspace set Object
overrideMethod @ VM2996 react_devtools_backend.js:4026
VM2996 react_devtools_backend.js:4026
Workspace set Object
overrideMethod @ VM2996 react_devtools_backend.js:4026
VM2996 react_devtools_backend.js:4026
Workspace roles undefined
overrideMethod @ VM2996 react_devtools_backend.js:4026
/api/workspaces/14a5ac49-c1bb-49b3-9d54-21bdad12b7f4/workspace-services:1
Failed to load resource: the server responded with a status of 403 (Forbidden)
VM2996 react_devtools_backend.js:4026```
Issue Analytics
- State:
- Created a year ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Insufficient permissions for device in Android Studio ...
I had this while using a Linux machine with a Nexus 4 running Android 5.1. The fix was to enable both 'debug over...
Read more >Insufficient Permission message when adding a user to the ...
Reason. Your enterprise role is missing the 'View Enterprise Directory' permission under the Contacts application. Resolution. An admin must ...
Read more >Insufficient Permissions Errors | Apigee Edge
The Insufficient permissions error typically means that the role assigned to the user does not have permissions to perform the requested operation. For...
Read more >Error: Insufficient permissions - Esri Support
This sample code shows how to add an edit operation to your code when using the IEditor interface. Code: Sub addPointToFirstLayer() Dim pMap...
Read more >Error 'Insufficient Privileges' when administrators login from ...
First check to see if there may be another user available in your org with the 'Manage User' permission. If so, that user...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks @damoodamoo - I’ve added the necessary permissions now and this works.
It would be good to include the response text from the API (which indicates the required roles for the user), along with any other helpful information (e.g. the App ID for the AAD app)
Your user (Stuart) needs to be WorkspaceOwner or WorkspaceUser of the Workspace that you are using
Maybe leave this bug as fixing the error message?