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: update permissions on classes with missing / unclear permissions #4667

Conversation

matthewelwell
Copy link
Contributor

@matthewelwell matthewelwell commented Sep 27, 2024

Changes

  1. Adds the required permission class to the SlackGetChannelsViewSet
  2. Moves the staff_member_required from urls.py to decorate the methods on the class for consistency with other permission definitions

How did you test this code?

Added new tests for permissions failure use cases. Existing tests cover happy paths.

@matthewelwell matthewelwell requested a review from a team as a code owner September 27, 2024 16:56
@matthewelwell matthewelwell requested review from khvn26 and removed request for a team September 27, 2024 16:56
@matthewelwell matthewelwell linked an issue Sep 27, 2024 that may be closed by this pull request
Copy link

vercel bot commented Sep 27, 2024

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

3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs ⬜️ Ignored (Inspect) Visit Preview Sep 30, 2024 9:27am
flagsmith-frontend-preview ⬜️ Ignored (Inspect) Visit Preview Sep 30, 2024 9:27am
flagsmith-frontend-staging ⬜️ Ignored (Inspect) Visit Preview Sep 30, 2024 9:27am

@matthewelwell matthewelwell marked this pull request as draft September 27, 2024 16:56
@github-actions github-actions bot added the api Issue related to the REST API label Sep 27, 2024
Copy link
Contributor

github-actions bot commented Sep 27, 2024

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-4667 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-e2e:pr-4667 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-frontend:pr-4667 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-api:pr-4667 Finished ✅ Results
ghcr.io/flagsmith/flagsmith:pr-4667 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-private-cloud:pr-4667 Finished ✅ Results

@github-actions github-actions bot added the fix label Sep 27, 2024
@matthewelwell matthewelwell removed the request for review from khvn26 September 27, 2024 16:57
Copy link
Contributor

github-actions bot commented Sep 27, 2024

Uffizzi Preview deployment-56707 was deleted.

@github-actions github-actions bot added fix and removed fix labels Sep 27, 2024
Copy link

codecov bot commented Sep 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.19%. Comparing base (dd1dd32) to head (0f8bf10).
Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4667   +/-   ##
=======================================
  Coverage   97.18%   97.19%           
=======================================
  Files        1166     1166           
  Lines       40369    40405   +36     
=======================================
+ Hits        39234    39270   +36     
  Misses       1135     1135           

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

@github-actions github-actions bot added fix and removed fix labels Sep 27, 2024
@matthewelwell matthewelwell marked this pull request as ready for review September 27, 2024 17:13
@github-actions github-actions bot added fix and removed fix labels Sep 27, 2024
@khvn26 khvn26 self-requested a review September 29, 2024 13:13
@github-actions github-actions bot removed the fix label Sep 30, 2024
@github-actions github-actions bot added the fix label Sep 30, 2024
@github-actions github-actions bot added fix and removed fix labels Sep 30, 2024
@matthewelwell matthewelwell added this pull request to the merge queue Sep 30, 2024
Merged via the queue into main with commit 19026e4 Sep 30, 2024
35 checks passed
@matthewelwell matthewelwell deleted the 4532-add-missing-permission_classes--get_permissions-to-views branch September 30, 2024 17:22
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 fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add missing permission_classes / get_permissions to views
2 participants