Skip to content

Add per-repository overrides for enabling PR's - #6028

Merged
intentionally-left-nil merged 1 commit into
mainfrom
feat/per-repo-pull-reviews
Sep 9, 2026
Merged

Add per-repository overrides for enabling PR's#6028
intentionally-left-nil merged 1 commit into
mainfrom
feat/per-repo-pull-reviews

Conversation

@intentionally-left-nil

Copy link
Copy Markdown
Contributor

Summary

If the user toggles off PR reviews for a specific repository, detect this during the incoming webhook and drop the request

Verification

Will test end-to-end in production after merging

);
const { prReviewMode } = resolveRepositorySettings(integration, repositoryCustomization);

if (prReviewMode === 'off') {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: Merge-commit synchronizes skip this toggle and can keep an in-flight review alive

Step 4 returns early for merge-commit synchronize events (e.g. GitHub "Update branch") before this check runs. Bot-authored PRs already compute their skip up front so that path cannot preserve a review the guardrail is meant to drop; prReviewMode === 'off' needs the same treatment.

If reviews are toggled off while a review is in flight and the next webhook is a merge-commit synchronize, migrateInFlightReviewsToMergeCommitHead re-points the review and opens a fresh check run instead of cancelling it.

Resolve prReviewMode before step 4 and treat 'off' like isBotPullRequestSkip so those events fall through to supersession and this skip.


Reply with @kilocode-bot fix it to have Kilo Code address this issue.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was a deliberate trade-off. If you do it the other way, then an old PR review would block any accepts until the reaping later.

TL;DR: If you toggle the setting mid-PR continuing any existing PR's is better than abandoning them

@kilo-code-bot

kilo-code-bot Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: 1 Issue Found | Recommendation: Address before merge

Overview

Severity Count
CRITICAL 0
WARNING 1
SUGGESTION 0
Issue Details (click to expand)

WARNING

File Line Issue
apps/web/src/lib/integrations/platforms/github/webhook-handlers/pull-request-handler.ts 317 Merge-commit synchronizes skip the PR-review toggle and can keep an in-flight review alive
Files Reviewed (2 files)
  • apps/web/src/lib/integrations/platforms/github/webhook-handlers/pull-request-handler.ts - 1 issue
  • apps/web/src/lib/integrations/platforms/github/webhook-handlers/pull-request-handler.test.ts

Fix these issues in Kilo Cloud


Reviewed by grok-4.6 · Input: 140.9K · Output: 19.4K · Cached: 216.8K

Review guidance: REVIEW.md from base branch main

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.

2 participants