Repository navigation
ref(control): Baseline the GitHub own-repo-PR check drop to on - #121954
Merged
vaind merged 1 commit intoAug 24, 2026
Merged
Conversation
The drop shipped off behind an option so a wrong predicate could be stopped without a deploy. Two days on the control silo say the predicate is right: check activity recorded held flat day over day (+2.2% check_run, +1.8% check_suite at the same clock), the downstream/upstream ratio never stepped at the cutover, and forwarding of checks that do carry an own-repo PR kept growing with traffic. It reclaimed ~8.1M webhookpayload rows a day. Carrying the rolled-out value in the registered default lets the automator drop its temporary control-silo override, which is the thing that has to be kept in sync by hand. The option stays registered and the call site keeps reading it, so setting it false is still the one-step revert. Only the control silo is affected: IntegrationControlMiddleware._should_operate returns early unless SiloMode is CONTROL, so region and monolith deployments never reach this parser regardless of the default. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
vaind
force-pushed
the
ivandlugos/cw-1838-baseline-drop-checks-without-own-repo-pr
branch
from
August 13, 2026 18:35
9b4b99a to
c9cd2d7
Compare
joseph-sentry
approved these changes
Aug 24, 2026
vaind
deleted the
ivandlugos/cw-1838-baseline-drop-checks-without-own-repo-pr
branch
August 24, 2026 12:34
vaind
added a commit
that referenced
this pull request
Aug 27, 2026
…lined The own-repo-PR predicate held its rollout override at `true` for a fortnight with `sentry.pr_metrics.check.activity_recorded` flat, which was the bar the rollout set for itself. #121954 moved that value into the registered default and sentry-options-automator#9218 removed the override, so the option has only ever been able to read `true` since. Collapsing the call site is what retires the switch; leaving the read in place would keep a branch nothing can reach. Drops the `has_own_repo_pr` tag on `github.webhook.forwarded_event` with it. Both action-filtered event types list `completed` in `own_repo_pr_actions`, so a payload that would tag `false` is now dropped before the forward and the tag is a constant. Emitting it cost a second `references_own_repo_pull_request` scan per completed check on the control parser's hot path. The tests that pinned the disabled path go too: the two kill-switch cases, the three asserting the `false` tag, and two `_by_default` cases that became exact duplicates of the `_with_no_pull_requests` drop tests once the option was gone.
vaind
added a commit
that referenced
this pull request
Sep 1, 2026
…lined The own-repo-PR predicate held its rollout override at `true` for a fortnight with `sentry.pr_metrics.check.activity_recorded` flat, which was the bar the rollout set for itself. #121954 moved that value into the registered default and sentry-options-automator#9218 removed the override, so the option has only ever been able to read `true` since. Collapsing the call site is what retires the switch; leaving the read in place would keep a branch nothing can reach. Drops the `has_own_repo_pr` tag on `github.webhook.forwarded_event` with it. Both action-filtered event types list `completed` in `own_repo_pr_actions`, so a payload that would tag `false` is now dropped before the forward and the tag is a constant. Emitting it cost a second `references_own_repo_pull_request` scan per completed check on the control parser's hot path. The tests that pinned the disabled path go too: the two kill-switch cases, the three asserting the `false` tag, and two `_by_default` cases that became exact duplicates of the `_with_no_pull_requests` drop tests once the option was gone.
vaind
added a commit
that referenced
this pull request
Sep 1, 2026
…lined (#122581) Step 3 of the option-removal order for `hybridcloud.webhookpayload.github_drop_checks_without_own_repo_pr`: the call site and the registration. The earlier steps are already out — #121954 moved the rolled-out value into the registered default (`False` → `True`), and [sentry-options-automator#9218](getsentry/sentry-options-automator#9218) removed the control-silo override that had held `true` since 2026-08-12. `options.get(...)` has only been able to return `true` since, so the branch behind it is unreachable. **Merge gate:** the automator run for [sentry-options-automator#9218](getsentry/sentry-options-automator#9218) needs to be green before this lands. It ran while the option was still registered, which is what lets `configoptions sync` unset the row — removing the registration first would strand it. ### What changed - `github.py` — dropped the `options.get(...)` conjunct, so the own-repo-PR drop is unconditional for the actions in `own_repo_pr_actions`. - `defaults.py` — removed the `register(...)`. - Dropped the `has_own_repo_pr` tag from `github.webhook.forwarded_event`. Both action-filtered event types list `completed` in `own_repo_pr_actions`, so any payload that would have tagged `false` is now dropped before the forward — the tag could only ever read `true`, and emitting it costs a second `references_own_repo_pull_request` scan on the control parser's hot path. If you group that counter by `has_own_repo_pr`: the split goes away, the counter does not. - Tests — removed the kill-switch cases, the ones asserting the dropped tag, and two `_by_default` cases that became exact duplicates of their `_with_no_pull_requests` counterparts. ### Testing `tests/sentry/middleware/integrations/parsers/test_github.py` — 62 passing. `prek` and mypy clean. ### Legal Boilerplate Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves the rolled-out value of
hybridcloud.webhookpayload.github_drop_checks_without_own_repo_printo the registered default, so the automator can drop its temporary control-silo override (options#9218).Baseline, not removal: the option stays registered and the parser keeps reading it, so setting it
falseis still the revert and needs no deploy.Why
The drop (#121719) shipped off behind an option because its predicate reads payload shape rather than a header — if it were wrong, real check activity would silently stop being recorded. Two days on the control silo say it is right. Same-clock 11:58–12:55Z windows, which avoids attributing the European CI ramp to the change:
check.activity_recordedcheck_runcheck.activity_recordedcheck_suiteforwarded_eventcheck_runhas_own_repo_pr:trueforwarded_eventcheck_suitehas_own_repo_pr:truedeliver_webhooks.savedprovider:githubThe self-normalizing test — recorded activity over forwarded events, which cancels out traffic volume — never stepped at the cutover: check_run held 0.72–0.88 and check_suite 0.73–0.92 across 30 hours spanning the toggle.
has_own_repo_pr:falsehas emitted nothing since 11:57Z on 08-12, one minute before these windows open. Net effect: roughly 18% fewer GitHub webhookpayload rows/day — about 14% of all rows, since GitHub is not the only provider writing them.Blast radius
Control silo only.
IntegrationControlMiddleware._should_operatereturns early unlessSiloModeisCONTROL, so region, single-tenant, and self-hosted deployments never reach this parser whatever the default says. The control silo already runstruevia the automator, so no live behavior changes here — only where the value comes from.Tests
Six tests depended on the old default:
..._is_forwarded_by_defaulttests become..._is_dropped_by_default, each gaining an explicitoption: Falsecounterpart covering the kill switch.forwarded_eventmetric tests assertinghas_own_repo_pr:"false"now pin the option off — with the drop on, that tag is unreachable.test_forwards_check_run_completed/test_forwards_check_suite_completednow carry an own-repo PR, so they exercise the mailbox routing that production actually takes.tests/sentry/middleware/integrations/passes, 174 tests.Merge order
Deploy this to all regions before merging options#9218. The other order drops the control-silo value while the deployed default is still
false, reverting the drop for the length of the gap.🤖 Generated with Claude Code