Open scottpgallagher opened 3 months ago
I ran into the same issue a couple of days ago. It certainly is an unexpected thing to happen, especially since assuming a request does refresh the resources.
I believe at the time when this was implemented, we ran into an "architectural" issue and we couldn't think of an easy way to fix this. Long story short, the function that refreshes resources cannot be called when dropping an access request due to hierarchy of React components.
However, I just talked about it with Grzegorz and there should be a straightforward way to address this. We need to move <ResourcesContext>
in the hierarchy as high as needed. Then the two functions exposed by this context need to accept an extra arg which is the URI of the workspace which should refresh its resources in all open tabs.
Expected behavior: When dropping an Access Request in Teleport Connect that the page would refresh what a user had access to prior to escalation.
Current behavior: Dropping an Access Request does not refresh the page.
Workaround: You can click on another tab (eg Pinned Resources) and back and the privileges/resources will referesh.
Bug details: