Skip to content

chore(preprod): Remove preprod-enforce-size-quota feature flag#118392

Merged
NicoHinderling merged 1 commit into
masterfrom
chore/remove-preprod-enforce-size-quota-flag
Jun 24, 2026
Merged

chore(preprod): Remove preprod-enforce-size-quota feature flag#118392
NicoHinderling merged 1 commit into
masterfrom
chore/remove-preprod-enforce-size-quota-flag

Conversation

@NicoHinderling

Copy link
Copy Markdown
Contributor

Summary

Graduates preprod size quota enforcement to always-on by removing the organizations:preprod-enforce-size-quota feature flag.

Previously, has_size_quota() short-circuited with an early return True whenever the flag was disabled, so size quota was never enforced for orgs without the flag. The flag has served its rollout purpose; this bakes in the enforced behavior so the quota check always runs.

Changes

  • Remove the flag registration from src/sentry/features/temporary.py.
  • Drop the flag gate in has_size_quota() (src/sentry/preprod/quotas.py); it now always calls quotas.backend.has_usage_quota(..., SIZE_ANALYSIS).
  • Remove the flag from the affected self.feature([...]) blocks in tests/sentry/preprod/test_tasks.py.

The sibling organizations:preprod-enforce-distribution-quota flag is intentionally left untouched.

Graduate size quota enforcement to always-on. The flag previously
gated an early return in has_size_quota() that skipped the quota
check entirely when disabled; now the check always runs.

Remove the flag registration, the gate in has_size_quota(), and the
flag from the affected task tests.
@NicoHinderling NicoHinderling requested a review from a team as a code owner June 24, 2026 20:04
@github-actions github-actions Bot added the Scope: Backend Automatically applied to PRs that change backend components label Jun 24, 2026
@NicoHinderling NicoHinderling enabled auto-merge (squash) June 24, 2026 20:37
@NicoHinderling NicoHinderling merged commit 7ee010f into master Jun 24, 2026
86 checks passed
@NicoHinderling NicoHinderling deleted the chore/remove-preprod-enforce-size-quota-flag branch June 24, 2026 21:48
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