-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
feat(aci): detector permission checks for DetectorWorkflow endpoint #88626
feat(aci): detector permission checks for DetectorWorkflow endpoint #88626
Conversation
src/sentry/workflow_engine/endpoints/validators/detector_workflow.py
Outdated
Show resolved
Hide resolved
tests/sentry/workflow_engine/endpoints/test_organization_detector_workflow_index.py
Outdated
Show resolved
Hide resolved
tests/sentry/workflow_engine/endpoints/test_organization_detector_workflow_index.py
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
high level approach on the org permissions looks great, just the suggestion around the check method and then spending some time breaking apart the tests would be good. I think you have a pretty good break down of each test in comment blocks, and could probably just pull out creating the models as a "setup" method and decompose around those comments.
tests/sentry/workflow_engine/endpoints/test_organization_detector_workflow_index.py
Outdated
Show resolved
Hide resolved
tests/sentry/workflow_engine/endpoints/test_organization_detector_workflow_index.py
Outdated
Show resolved
Hide resolved
tests/sentry/workflow_engine/endpoints/test_organization_detector_workflow_index.py
Outdated
Show resolved
Hide resolved
src/sentry/workflow_engine/endpoints/validators/detector_workflow.py
Outdated
Show resolved
Hide resolved
src/sentry/workflow_engine/endpoints/validators/detector_workflow.py
Outdated
Show resolved
Hide resolved
❌ 2 Tests Failed:
View the top 2 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👩🍳 nice job on implementing the feedback
ce58dee
into
mia/aci/detector-workflow-endpoint
detectors should have similar permissions to alerts today, with additional restrictions on default detectors created by Sentry
org:write
ororg:admin
)project:write
on the project)alert:write
on projects)