fix(gateway): gate semantic reviews behind CI #72

Merged
jwilger merged 3 commits from fix/issue-44-ci-gated-reviews into main 2026-05-04 12:20:49 -07:00
Owner

Summary

  • Stop ordinary pull_request webhooks, including opened/synchronized and bot review_requested events, from dispatching semantic ReviewJobs by default.
  • Keep CI-triggered /reviews/ci dispatch and explicit @auto_review re-review forced reviews, with re-review status explaining the intentional CI-gating bypass.
  • Update operator/deployment docs and CI-token wiring for the new webhook-intake vs CI-dispatch lifecycle.

Verification

  • nix develop -c cargo fmt --all -- --check
  • nix develop -c cargo nextest run -p ar-gateway -E 'test(valid_pr_opened_and_synchronized_are_accepted_without_dispatching_review) | test(review_requested_for_configured_bot_is_accepted_without_dispatching_review) | test(metrics_track_pr_webhook_intake_without_review_dispatch) | test(webhook_dedup_replies_ok_without_dispatching_on_retry) | test(webhook_dedup_passes_through_when_no_delivery_header) | test(ci_review_endpoint_fetches_matching_pr_and_dispatches_review_job)'
  • nix develop -c cargo nextest run -p ar-chat -E 'test(re_review_with_dispatcher_queues_force_job) | test(remember_stores_learning_and_replies_with_id)'
  • nix develop -c cargo nextest run -p ar-gateway -p ar-chat --no-tests=pass
  • nix develop -c cargo clippy --workspace --all-targets -- -D warnings

Skipped: helm template validation because helm is not installed in the Nix dev shell.

Closes #44.

## Summary - Stop ordinary pull_request webhooks, including opened/synchronized and bot review_requested events, from dispatching semantic ReviewJobs by default. - Keep CI-triggered /reviews/ci dispatch and explicit @auto_review re-review forced reviews, with re-review status explaining the intentional CI-gating bypass. - Update operator/deployment docs and CI-token wiring for the new webhook-intake vs CI-dispatch lifecycle. ## Verification - nix develop -c cargo fmt --all -- --check - nix develop -c cargo nextest run -p ar-gateway -E 'test(valid_pr_opened_and_synchronized_are_accepted_without_dispatching_review) | test(review_requested_for_configured_bot_is_accepted_without_dispatching_review) | test(metrics_track_pr_webhook_intake_without_review_dispatch) | test(webhook_dedup_replies_ok_without_dispatching_on_retry) | test(webhook_dedup_passes_through_when_no_delivery_header) | test(ci_review_endpoint_fetches_matching_pr_and_dispatches_review_job)' - nix develop -c cargo nextest run -p ar-chat -E 'test(re_review_with_dispatcher_queues_force_job) | test(remember_stores_learning_and_replies_with_id)' - nix develop -c cargo nextest run -p ar-gateway -p ar-chat --no-tests=pass - nix develop -c cargo clippy --workspace --all-targets -- -D warnings Skipped: helm template validation because helm is not installed in the Nix dev shell. Closes #44.
fix(gateway): gate semantic reviews behind CI
Some checks failed
CI / Nix flake check (pull_request) Failing after 2m31s
CI / auto_review semantic review (pull_request) Has been skipped
4d8e070bc7
chore(dev): include helm in dev shell
Some checks failed
CI / Nix flake check (pull_request) Failing after 1m44s
CI / auto_review semantic review (pull_request) Has been skipped
6250861d59
test(orchestrator): drive synthetic e2e through CI endpoint
All checks were successful
CI / Nix flake check (pull_request) Successful in 2m31s
CI / auto_review semantic review (pull_request) Successful in 1s
auto_review auto_review: no findings
bf980be84e
auto-review left a comment

This PR modifies the review dispatch process to be CI-gated, stopping automatic dispatch from ordinary PR webhooks. It updates documentation and tests to reflect this change, ensuring that reviews are only triggered after CI prerequisites are met or through explicit commands. The changes appear well-implemented and safe to merge.

Walkthrough

  • Documentation Updates:

    • Updated various markdown files to reflect the new CI-gated review process, ensuring users understand the new workflow.
    • Added instructions for setting up CI tokens and triggering reviews via CI workflows.
  • Code Changes:

    • Modified ar-gateway to accept PR webhooks without dispatching reviews, aligning with the new CI-gated process.
    • Updated ar-chat to include messages about bypassing CI gating for forced reviews.
  • Test Updates:

    • Adjusted tests in ar-gateway and ar-orchestrator to verify the new behavior of accepting webhooks without dispatching reviews and using the CI endpoint for triggering reviews.
This PR modifies the review dispatch process to be CI-gated, stopping automatic dispatch from ordinary PR webhooks. It updates documentation and tests to reflect this change, ensuring that reviews are only triggered after CI prerequisites are met or through explicit commands. The changes appear well-implemented and safe to merge. ## Walkthrough - **Documentation Updates**: - Updated various markdown files to reflect the new CI-gated review process, ensuring users understand the new workflow. - Added instructions for setting up CI tokens and triggering reviews via CI workflows. - **Code Changes**: - Modified `ar-gateway` to accept PR webhooks without dispatching reviews, aligning with the new CI-gated process. - Updated `ar-chat` to include messages about bypassing CI gating for forced reviews. - **Test Updates**: - Adjusted tests in `ar-gateway` and `ar-orchestrator` to verify the new behavior of accepting webhooks without dispatching reviews and using the CI endpoint for triggering reviews.
jwilger deleted branch fix/issue-44-ci-gated-reviews 2026-05-04 12:20:49 -07:00
jwilger referenced this pull request from a commit 2026-05-05 12:18:07 -07:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Slipstream/auto_review!72
No description provided.