Skip to content

ref(replays): Clean up granular-replay-permissions feature flag (backend)#110036

Merged
priscilawebdev merged 2 commits intomasterfrom
ref/clean-up-granular-replay-permissions-flag
Mar 11, 2026
Merged

ref(replays): Clean up granular-replay-permissions feature flag (backend)#110036
priscilawebdev merged 2 commits intomasterfrom
ref/clean-up-granular-replay-permissions-flag

Conversation

@priscilawebdev
Copy link
Member

@priscilawebdev priscilawebdev commented Mar 6, 2026

Remove the organizations:granular-replay-permissions feature flag so granular replay permissions are always available. The org option sentry:granular-replay-permissions still controls whether the feature is active per-organization.

Changes:

  • Remove the flag from temporary.py
  • Remove features.has() checks in permissions.py, organization.py serializer, and organization_details.py validation
  • Always serialize hasGranularReplayPermissions and replayAccessMembers based on the org option (no longer gated behind the feature flag)
  • Remove tests that asserted feature-flag-gating behavior
  • Remove @with_feature decorators and self.feature() context managers for this flag from remaining tests

Refs TET-2017

Remove the `organizations:granular-replay-permissions` feature flag
so the granular replay permissions feature is always available. The
org option `sentry:granular-replay-permissions` still controls whether
the feature is active per-organization.

Refs TET-2017
Co-Authored-By: Claude <noreply@anthropic.com>
@linear-code
Copy link

linear-code bot commented Mar 6, 2026

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Mar 6, 2026
@priscilawebdev priscilawebdev marked this pull request as ready for review March 6, 2026 11:26
@priscilawebdev priscilawebdev requested a review from a team as a code owner March 6, 2026 11:26
@priscilawebdev priscilawebdev requested a review from a team March 6, 2026 11:26
manager.add("organizations:gen-ai-consent", OrganizationFeature, FeatureHandlerStrategy.FLAGPOLE, api_expose=True)
# Enable granular permissions for replay features
manager.add("organizations:granular-replay-permissions", OrganizationFeature, FeatureHandlerStrategy.FLAGPOLE, api_expose=True)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feature flag registration should be removed last (see docs) - this should be done at the very end I think

Copy link
Member

@shellmayr shellmayr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good - but I think we should remove the frontend portion of this first - the frontend retrieves the info about the feature flag from the API, so if we remove it in the API, the feature will stop working until the frontend is merged, and we shouldn't let that happen.

Restoring the flag registration to be removed in a follow-up PR per flagpole removal docs.

Co-Authored-By: Claude Sonnet 4 <noreply@anthropic.com>
@priscilawebdev priscilawebdev enabled auto-merge (squash) March 11, 2026 07:33
@priscilawebdev priscilawebdev merged commit 6b8b571 into master Mar 11, 2026
61 checks passed
@priscilawebdev priscilawebdev deleted the ref/clean-up-granular-replay-permissions-flag branch March 11, 2026 07:53
priscilawebdev added a commit that referenced this pull request Mar 11, 2026
…110397)

Removes the `organizations:granular-replay-permissions` feature flag
registration from `temporary.py`. This is the final cleanup step per the
[flagpole removal
docs](https://develop.sentry.dev/backend/application-domains/feature-flags/flagpole/#removing-flagpole-features),
to be merged after #110036.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants