Flagsmith / flagsmith

Open Source Feature Flagging and Remote Config Service. Host on-prem or use our hosted version at https://flagsmith.com/
https://flagsmith.com/
BSD 3-Clause "New" or "Revised" License
4.77k stars 365 forks source link

fix: update permissions on classes with missing / unclear permissions #4667

Closed matthewelwell closed 2 days ago

matthewelwell commented 5 days ago

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.

vercel[bot] commented 5 days ago

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

3 Skipped Deployments | Name | Status | Preview | Comments | Updated (UTC) | | :--- | :----- | :------ | :------- | :------ | | **docs** | ⬜️ Ignored ([Inspect](https://vercel.com/flagsmith/docs/C7pLEQD57HK1e6N7RfG2crzmZnJi)) | [Visit Preview](https://docs-git-4532-add-missing-permissionclasses-ge-487fbb-flagsmith.vercel.app) | | Sep 30, 2024 9:27am | | **flagsmith-frontend-preview** | ⬜️ Ignored ([Inspect](https://vercel.com/flagsmith/flagsmith-frontend-preview/HZX4keXRSFLj9ar5imSQ9WNeQDE4)) | [Visit Preview](https://flagsmith-frontend-preview-git-4532-add-missin-454f51-flagsmith.vercel.app) | | Sep 30, 2024 9:27am | | **flagsmith-frontend-staging** | ⬜️ Ignored ([Inspect](https://vercel.com/flagsmith/flagsmith-frontend-staging/2x3t5b52rZwjQ7PcqN5cpTsHXRNc)) | [Visit Preview](https://flagsmith-frontend-staging-git-4532-add-missin-cfb88c-flagsmith.vercel.app) | | Sep 30, 2024 9:27am |
github-actions[bot] commented 5 days ago

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-4667 Finished :white_check_mark: Skipped
ghcr.io/flagsmith/flagsmith-e2e:pr-4667 Finished :white_check_mark: Skipped
ghcr.io/flagsmith/flagsmith-frontend:pr-4667 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith-api:pr-4667 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith:pr-4667 Finished :white_check_mark: Results :white_check_mark:
ghcr.io/flagsmith/flagsmith-private-cloud:pr-4667 Finished :white_check_mark: Results :white_check_mark:
github-actions[bot] commented 5 days ago

Uffizzi Preview deployment-56707 was deleted.

codecov[bot] commented 5 days ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

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

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

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.