feat(repos): Activate repo webhook and syncing task for GHE#112247
Merged
feat(repos): Activate repo webhook and syncing task for GHE#112247
Conversation
Comment on lines
355
to
361
| "push": GitHubEnterprisePushEventWebhook, | ||
| "pull_request": GitHubEnterprisePullRequestEventWebhook, | ||
| "installation": GitHubEnterpriseInstallationEventWebhook, | ||
| "installation_repositories": GitHubEnterpriseInstallationRepositoriesEventWebhook, | ||
| "issues": GitHubEnterpriseIssuesEventWebhook, | ||
| } | ||
|
|
Contributor
There was a problem hiding this comment.
Bug: The GitHubEnterpriseWebhookEndpoint uses @cell_silo_endpoint, but middleware routes installation_repositories events to the CONTROL silo, causing a routing conflict and request failure.
Severity: HIGH
Suggested Fix
Change the decorator on GitHubEnterpriseWebhookEndpoint from @cell_silo_endpoint to @all_silo_endpoint. This will allow the endpoint to execute in both CELL and CONTROL silos, resolving the conflict with the middleware's routing logic for control-only events.
Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: src/sentry/integrations/github_enterprise/webhook.py#L355-L361
Potential issue: There is a silo routing conflict for the GitHub Enterprise
`installation_repositories` webhook event. The middleware correctly identifies this
event as control-silo-only and routes the request to the CONTROL silo. However, the
`GitHubEnterpriseWebhookEndpoint` is decorated with `@cell_silo_endpoint`, which
enforces that it can only run in the CELL silo. When the request is dispatched in
CONTROL silo mode, the decorator will reject it, resulting in a 404 error or an
`AvailabilityError`. This will cause webhook deliveries for repository updates to fail,
preventing repository data from being synchronized.
Did we get this right? 👍 / 👎 to inform future reviews.
63cd983 to
1cd4146
Compare
1cd4146 to
ce212d5
Compare
4221d01 to
cf95da8
Compare
This enables the same github syncing for GHE
cf95da8 to
c0857f8
Compare
evanpurkhiser
approved these changes
Apr 7, 2026
george-sentry
pushed a commit
that referenced
this pull request
Apr 9, 2026
This enables the same github syncing for GHE <!-- Describe your PR here. -->
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.
This enables the same github syncing for GHE