fix(seer-slack): Skip subscription-gated access check in control silo#113716
Merged
fix(seer-slack): Skip subscription-gated access check in control silo#113716
Conversation
resolve_seer_organization is called from the control-silo parser in _filter_organizations_for_seer_event. Its SlackExplorerEntrypoint.has_access check runs features.batch_has for seer-explorer / autofix-on-explorer, whose Flagpole rules gate on subscription_* context. getsentry's FlagpoleFeatureHandler intentionally skips the subscription fetch in control silo for latency reasons (getsentry 958790ccea), so those rules evaluated False for every OrganizationIntegration in the loop, halting all Seer Slack events with NO_VALID_ORGANIZATION and surfacing "Check Settings" DMs to users who previously had working Seer interactions. Split has_access into has_feature_flag (Slack feature flag only) and the full subscription-gated has_access. The parser's control-silo pass uses the cheaper has_feature_flag; the cell handler reruns the full has_access after routing, where subscription context is available. Add debug logging on every skip reason inside the loop so future regressions can be diagnosed from logs rather than guesswork. Refs ISWF-2494 Co-Authored-By: Claude <noreply@anthropic.com>
…string Promote the per-skip logs in resolve_seer_organization from debug to info so they ship to log aggregation and can diagnose future resolution regressions without a code change. Serialize `silo_mode` via `.value` so the enum is rendered as a plain string in structured logs rather than an enum repr that may not serialize cleanly through every handler. Rewrite the has_access docstring to name the real constraint: must not be called from control silo, because getsentry's FlagpoleFeatureHandler skips subscription context there and any subscription-gated Flagpole rule evaluates False. Point callers to has_feature_flag for the control-silo path. Refs ISWF-2494 Co-Authored-By: Claude <noreply@anthropic.com>
alexsohn1126
approved these changes
Apr 22, 2026
leeandher
added a commit
that referenced
this pull request
Apr 23, 2026
A revert-revert of #113473, but with the debug changes + silo caveats for feature flag checking. This one shouldn't cause issues, but even though tests pass this is really difficult to check, so we're relying on the log changes from #113716 to validate before merging. I added the new kwargs for the task from #113599 + changed error_reason to halt_reason here to avoid some merge conflicts in my next PR. --------- Co-authored-by: Claude <noreply@anthropic.com>
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.
Parser's
_filter_organizations_for_seer_eventrunsresolve_seer_organizationfrom control silo, butSlackExplorerEntrypoint.has_accessdepends on Flagpole rules that gate onsubscription_*context — and getsentry'sFlagpoleFeatureHandlerintentionally skips the subscription fetch in control silo, so every resolution was halting withNO_VALID_ORGANIZATIONand DMing users "Check Settings". :(Split
has_accessintohas_feature_flag(Slack flag only) for the control-silo parser pass and the full subscription-gatedhas_accessfor the cell handler, which reruns resolution after routing.Refs ISWF-2494