Skip to content

fix(review-kit): skip non-PR events before expansion#291

Merged
khaliqgant merged 1 commit into
mainfrom
codex/issue-290-reviewkit-nonpr
Jul 17, 2026
Merged

fix(review-kit): skip non-PR events before expansion#291
khaliqgant merged 1 commit into
mainfrom
codex/issue-290-reviewkit-nonpr

Conversation

@miyaontherelay

Copy link
Copy Markdown
Contributor

Fixes #290.

Summary

  • skip non-GitHub-pull-request events before calling expand("full")
  • log stable review-kit.skipped evidence with reason=non-pull-request-event and eventType
  • preserve genuine PR expansion failures and the existing malformed-payload unreadable-pull-request guard
  • document the fix in the published review-kit changelog

Regression coverage

  • uses the production envelopeToAgentEvent mapper to construct the manual cron.tick shape and proves its full expansion is unavailable
  • verifies that manual cron delivery returns cleanly without harness execution or writeback
  • verifies genuine PR expansion errors retain the same error identity and are not swallowed
  • verifies malformed expanded PR payloads retain the existing skip reason
  • existing genuine PR review, deploy extraction, idempotency, delivery, and packaging contracts remain green

Validation

  • pnpm --filter @agentworkforce/review-kit test — 30/30
  • pnpm --filter @agentworkforce/review-kit typecheck
  • pnpm --filter @agentworkforce/review-kit lint
  • pnpm build
  • pnpm typecheck
  • pnpm --filter @agentworkforce/review-kit pack --pack-destination /tmp/review-kit-290-pack plus tarball compiled-surface inspection
  • runtime suite — relevant cron/provider expansion contracts pass; 134/147 overall, with the same 13 local-preview tests requiring patched Node >=26.3.1 while this host is Node 25.8.1

Review

  • independent adversarial shadow review of the exact candidate: green, no requested changes

@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@miyaontherelay

Copy link
Copy Markdown
Contributor Author

@codex review

@miyaontherelay

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@chatgpt-codex-connector

Copy link
Copy Markdown

To use Codex here, create a Codex account and connect to github.

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

No new commits to review since the last review.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 4f968407-6399-453d-adb0-5088c948807e

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The review handler now filters non-pull-request events before gateway expansion. Tests cover skip logging, expansion failures, and malformed payloads. The changelog documents the fix and updates version 4.1.29 entries.

Changes

Review-kit event filtering

Layer / File(s) Summary
Event filtering and validation
packages/review-kit/src/agent.ts, packages/review-kit/src/review-kit.test.ts, packages/review-kit/CHANGELOG.md
The handler skips non-pull-request events before expansion, tests expansion and malformed-payload outcomes, and documents the updated behavior and evidence-provider entries.

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

A rabbit guards the gateway door,
No stray events can tumble through.
PRs may hop along the floor,
Bad shapes are logged and gently shooed.
The changelog sprouts a leaf anew.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: skipping non-PR events before expansion.
Description check ✅ Passed The description is directly related to the PR and matches the implemented behavior and tests.
Linked Issues check ✅ Passed The changes satisfy #290 by skipping non-PR events before expansion, logging the skip, and preserving PR expansion and malformed-payload behavior.
Out of Scope Changes check ✅ Passed The changelog and added regression tests are aligned with the issue and do not appear out of scope.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/issue-290-reviewkit-nonpr

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@khaliqgant
khaliqgant merged commit 62dea7c into main Jul 17, 2026
3 checks passed
@khaliqgant
khaliqgant deleted the codex/issue-290-reviewkit-nonpr branch July 17, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

review-kit: agent throws (unhandled runner.handler.error) on non-PR events instead of skipping cleanly

2 participants