OfficeDev / microsoft-teams-emergency-operations-center

The Microsoft Teams Emergency Operations Center (TEOC) solution template leverages the power of the Microsoft 365 platform to centralize incident response, information sharing and field communications using powerful services like Microsoft Lists, SharePoint and more.
MIT License
95 stars 40 forks source link

Error creating incident #174

Closed ABNOTECHGuy closed 5 months ago

ABNOTECHGuy commented 9 months ago

Hi, When trying to create the first incident the following error is displayed: image

Have I misconfigured something?

v-ajaysahu commented 9 months ago

@ABNOTECHGuy , Thank you for reporting this. Please open teams in browser, then open the app and share console logs and network trace which will help us troubleshoot the issue. Also request you to share the manifest files with us.

ABNOTECHGuy commented 9 months ago

Hi @v-ajaysahu,

I was able to see that there were other incidents with similar problem and found the fix was that I had to add my test user account to the Group Administrator Azure role. (Not ideal but I can work with it).

Now I'm having a similar issue when trying to UPDATE in incident with additional users in the Secondary Incident Commander role, any other role it works fine and I'm guessing it has something to do with that role making the user a co-owner of the team.

It errors when saving. Does the user being added have to have the Azure Group Admin role too?, or is there another role requirement that the test user account would need to update the incident?

v-ajaysahu commented 9 months ago

Hi @ABNOTECHGuy , Could you please upgrade to latest version. If you're still facing issue in creation of Incident kindly let us know with the logs. And Only Incident Commander or Secondary Incident Commanders will be able to update the incident. If user want access to edit incident, he must be in any of the roles.

v-ajaysahu commented 8 months ago

@ABNOTECHGuy , can you please confirm if the issue is resolved after upgrading it to latest version? If it is resolved, can we close this ticket?

ABNOTECHGuy commented 8 months ago

@v-ajaysahu, not sure if upgrading to v3.0 actually fixed it as I was still having the problem immediately after doing the update. However, I have managed to resolve it myself. Based on the below console output it seems there is a bug when adding a user as both Role Lead and Member to the Secondary Incident Commander role:

IncidentDetails.tsx:2969 EOC-Error: UpdateIncident_AddUsersToTeam {"statusCode":400,"code":"BadRequest","requestId":"862b45b5-321a-4c52-80c4-c5f909e95c48","date":"2024-02-28T19:55:19.000Z","body":"{\"code\":\"BadRequest\",\"message\":\"User Ids in the payload must be unique. Following members were present multiple times '90bfd2d5-abca-489e-bf8d-4d27d7a1acc4'\",\"innerError\":{\"date\":\"2024-02-29T05:55:19\",\"request-id\":\"862b45b5-321a-4c52-80c4-c5f909e95c48\",\"client-request-id\":\"edc4e4a3-df0d-6b2b-7225-12085a6152d4\"}}"}

So by not adding the user to "Role Lead" and only to the "Member" field when adding a SIC, then it succeeds. This makes sense because you can't have someone added to a Team as both an Owner and a Member.

image

Perhaps if this can be made clear in the documentation, or in the GUI change the role options for the Secondary IC to only show the member field, then that would prevent these errors for future users.

v-ajaysahu commented 8 months ago

@ABNOTECHGuy , this is handled in the latest version. Requesting you to upgrading it to latest version and try again. Kindly let us know if you're still facing issue.

ABNOTECHGuy commented 8 months ago

Hi @v-ajaysahu,

As I mentioned, I have completed the upgrade but it did not fix the issue with Secondary Incident Commander role.

v-ajaysahu commented 8 months ago

@ABNOTECHGuy , Thank you for reporting this. We will address this scenario in upcoming release.

v-saikirang commented 5 months ago

Hi @ABNOTECHGuy,

This issue is fixed in latest version v3.1. Please check and let us know if you see any issues. For now we are closing this ticket. Thanks.