fix(seer): Capture GitLab webhook validation failures as exceptions#117969
Merged
billyvg merged 6 commits intoJun 18, 2026
Conversation
Co-Authored-By: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com>
a7936a4 to
84e762c
Compare
Co-Authored-By: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com>
vaind
approved these changes
Jun 18, 2026
Co-Authored-By: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 8555892. Configure here.
Co-Authored-By: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.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.

Summary
When a GitLab
merge_requestor note webhook payload failsSeerCodeReviewTaskRequestvalidation,_schedule_taskdrops the review entirely — it never reaches Seer, yet GitLab still receives a200. Today this is only adebug_logat WARNING level, so the silent drops are effectively invisible.This replaces the
validation_failed/note.validation_faileddebug logs withsentry_sdk.capture_exception, so a dropped review surfaces as a Sentry issue and can be triaged.Changes
except ValidationErrorblocks (MR-event path and@sentry reviewnote path) nowcapture_exception(e)inside a scope that carries thevalidation_errorsandseer_path(ormr_iid) as context for triage.record_webhook_filtered(..., INVALID_PAYLOAD)is retained — the metric is still useful.Why
A validation failure is not a benign "filtered" event — it means we accepted the webhook but never ran the review the customer expected. That deserves escalation, not a debug log. (This is the same failure mode behind the
trigger_atdatetime bug; see related PR.)Tests
test_validation_failure_is_captured_and_review_dropped— forces aValidationError, assertscapture_exceptionis called with it and the Seer task is not enqueued.Note
Independent of (not stacked on) the
trigger_atnormalization PR — they touch different code paths in the same file and can merge in any order.🤖 Generated with Claude Code