Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Reading role permissions generates 500 errors #3009

Merged
merged 30 commits into from
Jan 11, 2024

Conversation

novakzaballa
Copy link
Contributor

@novakzaballa novakzaballa commented Nov 20, 2023

Thanks for submitting a PR! Please check the boxes below:

  • I have run pre-commit to check linting
  • I have filled in the "Changes" section below?
  • I have filled in the "How did you test this code" section below?
  • I have used a Conventional Commit title for this Pull Request

Changes

  • Skip requests when the role organization is not sent
  • Use new RBAC endpoint to retrieve and delete userRoles by user

How did you test this code?

  • Go to manage -> members -> Users
  • Open the Network tab
  • Click any User
  • The error is no longer there

Copy link

vercel bot commented Nov 20, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 8, 2024 7:05pm
flagsmith-frontend-preview 🛑 Canceled (Inspect) Jan 8, 2024 7:05pm
flagsmith-frontend-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 8, 2024 7:05pm

@github-actions github-actions bot added the front-end Issue related to the React Front End Dashboard label Nov 20, 2023
Copy link
Contributor

github-actions bot commented Nov 20, 2023

Uffizzi Preview deployment-41151 was deleted.

@novakzaballa novakzaballa requested review from a team and kyle-ssg and removed request for a team November 20, 2023 23:04
@matthewelwell matthewelwell marked this pull request as draft November 21, 2023 09:43
@matthewelwell
Copy link
Contributor

Based on this Slack thread, I'm not sure this is the right solution. All roles should have an organisation attribute. I've marked this PR as draft until we have understood more about this.

frontend/web/components/EditPermissions.tsx Outdated Show resolved Hide resolved
frontend/web/components/EditPermissions.tsx Outdated Show resolved Hide resolved
@github-actions github-actions bot added the api Issue related to the REST API label Nov 28, 2023
@codecov-commenter
Copy link

codecov-commenter commented Nov 28, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (9f83f27) 95.99% compared to head (b54b420) 95.99%.
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3009   +/-   ##
=======================================
  Coverage   95.99%   95.99%           
=======================================
  Files        1062     1062           
  Lines       32297    32297           
=======================================
  Hits        31005    31005           
  Misses       1292     1292           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@gagantrivedi
Copy link
Member

image
Looks like it's trying to use environment API key for organisation ID?

@novakzaballa
Copy link
Contributor Author

image Looks like it's trying to use environment API key for organisation ID?

Corrected.

@gnumoreno
Copy link
Contributor

gnumoreno commented Jan 9, 2024

@novakzaballa I'm not sure if this code touches on it but if I go to https://app.flagsmith.com/organisation-settings -> member - groups - create a new group, the new group does not show up. I have to navigate to complete refresh the page for the group to show up.

@gnumoreno
Copy link
Contributor

Other than the group thing I commented above, the approvers seems to be working just fine. I still think the user experience is confusing but I will take some time later this week and open a separate issue

@novakzaballa
Copy link
Contributor Author

@novakzaballa I'm not sure if this code touches on it but if I go to https://app.flagsmith.com/organisation-settings -> member - groups - create a new group, the new group does not show up. I have to navigate to complete refresh the page for the group to show up.

@gnumoreno That part of the code was not touched, this is a good catch, we would have to create an issue.

@novakzaballa novakzaballa added this pull request to the merge queue Jan 11, 2024
Merged via the queue into main with commit de5cf9d Jan 11, 2024
21 checks passed
@novakzaballa novakzaballa deleted the fix/reading-role-permissions-generates-500-error branch January 11, 2024 13:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Issue related to the REST API front-end Issue related to the React Front End Dashboard
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Reading role permissions generates 500 errors
7 participants