Fix: bound automatic PR synchronize reviews and cancel stale jobs - #5
Open
petergstfsn wants to merge 1 commit into
Open
petergstfsn wants to merge 1 commit into
petergstfsn wants to merge 1 commit into
Conversation
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
codra | 9f5cca3 | Sep 22 2026, 04:17 AM |
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.
Motivation
synchronize) and thereby consuming model and queue resources.Description
author_association/authorAssociationto webhook payload types and the normalization output (packages/schema/*,packages/provider-github/src/webhook.ts).change_request/synchronizereview extraction for authors without a trusted repository role (OWNER,MEMBER,COLLABORATOR) inextractReviewRequest, so untrusted fork pushes are acknowledged but not queued (packages/core/src/review/request.ts).synchronizedeliveries that were rejected by policy before persisting or enqueueing work (packages/api/src/routes/webhook.ts).commitShano longer matches the current PR head in preparation (runPreparePhase) and revalidate before any later phase so stale queue entries do not perform diffs, model calls, checks, or reviews (packages/core/src/review/prepare.ts,packages/core/src/review/index.ts).cancelJobmethod to the job store port and wire it through the DB repository and in-memory test runtime (packages/core/src/ports/jobs.ts,packages/db/src/repositories/jobs-repository.ts,packages/core/test/in-memory.ts).synchronizeevents, allowed collaboratorsynchronizeevents, and stale-job cancellation (test/api/webhook-handling.spec.ts,packages/core/test/stale-job.spec.ts).Testing
npx vitest run test/api/webhook-handling.spec.ts --reporter=dot, all tests passed.npm test -w @codraoss/core -- --run test/stale-job.spec.ts --reporter=verbose, tests passed.npm run typecheck -- --pretty falseandnpm run lint -- --no-warn-ignored, both completed without errors.git diff --checkreturned no whitespace errors.Codex Task