Repository navigation
fix(review): mark the PR-platform status post explicitly - #1719
Merged
Merged
Conversation
Since 0.28.0 reviewHostResult treated an annotated review with zero annotations as the PR-platform status post (noop), so under the Claude Code mod a review made only of PR description comments, PR comment notes or VS Code editor comments (which ride only in the feedback markdown) reached Claude as nothing, and the draft was cleared. The platform path's status post now sends `platform: true` in its /api/feedback body; both review servers carry it onto the decision only when it is boolean true, and every consumer decides on that flag instead of the annotation count: the host result record, the CLI output (stdout and --json), OpenCode's embedded command and CLI bridge (which falls back to isPRMode for an older CLI), and Pi (classifyReviewOutcome). Zero-annotation feedback is now delivered and gets the request-changes suffix; a truly empty submit stays a no-op.
0.28.0-0.28.3 CLIs wrote platform: true, noop: true for any review with zero code annotations. The mod now treats a review record as the platform post only when its message is one of the editor's status lines, and delivers any other platform record as review feedback. Also corrects the flag's wording: only the mod logs the status post; OpenCode, Pi, CLI stdout and Amp deliver it verbatim without the request-changes suffix.
backnotprop
added a commit
that referenced
this pull request
Oct 5, 2026
Brings in #1719 (platform flag), #1717, 0.28.4 and #1718 (bundles). Resolution keeps both sides: - Pi review delivery uses classifyReviewOutcome (the server's platform flag; nothing inferred from the annotation count) inside the shared launchCodeReview, with this branch's decision heading. The platform status post is labeled "Posted to the pull request". - Bundles go through launchAnnotate, shared by /plannotator-annotate and the tool. A tool list target opens one annotate-bundle review in order (only the shared selection's bundle outcome opens; missing, folder or URL entries refuse). Its subject is plannotatorBundleSubject in the result, list, close and decision heading. - Tests: bundle via the tool (order, list, feedback, close), a list that would open fewer files refuses, description-only review feedback through the tool path, and the platform post delivered verbatim. Co-Authored-By: Claude <noreply@anthropic.com>
backnotprop
added a commit
that referenced
this pull request
Oct 5, 2026
Brings in #1719 (explicit review `platform` flag), #1717, 0.28.4 and #1718 (bundles). Resolutions and follow-ups: - cli-bridge annotate: bundle framing ("Files: …") and the older-CLI several-paths mapping kept, plus the tool's gated bare approval, failure reports and the agent-close log. - The tool opens a list target as one bundle review through the same launch (annotateBundle: each file its own CLI argument; a single tool target is never re-split); the subject is plannotatorBundleSubject in the result, list and decision heading; an older CLI's refusal answers the bundle update text. Slash-command bundles get the same subject. - Review headings use the platform flag (isPlatformPost, isPRMode fallback only without the flag): "Review posted" for the status post, "Changes requested" for anything else, never inferred from zero annotations. - opencode-review carries both #1719's platform and the additive annotationCount. - Tests: a bundle via the tool (argv order, name, list, heading, older CLI), description-only PR feedback vs a platform post. Co-Authored-By: Claude <noreply@anthropic.com>
1 task
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.
Problem
Since 0.28.0,
reviewHostResult(apps/hook/server/host-result.ts) read any request-changes review with zero annotations as the PR-platform status post:noop: true. The review editor puts only code comments inannotations. PR description comments, PR comment notes and VS Code editor comments go only into the feedback markdown. So under the Claude Code mod, a review made only of those comments sent Claude nothing, and the server had already cleared the draft.Fix
The platform post now marks itself, and nothing infers it from the annotation count.
packages/review-editor/App.tsx): the status post that follows a platform submission sendsplatform: truein its/api/feedbackbody. No other body sends it.packages/server/review.ts,apps/pi-extension/server/serverReview.ts): putplatform: trueon the decision only when the body value is booleantrue.reviewHostResult: with the flag,noop: trueandplatform: true. Feedback without the flag is delivered (noop: false), includingannotationCount: 0. A submit with no feedback text and no annotations stays a no-op.buildReviewOutput(CLI stdout and--json, which Amp reads): every review gets the request-changes suffix except the platform status line./plannotator-review: same rule.opencode-reviewalways sendsplatformas a boolean. When the field is missing, the CLI is older, and the bridge falls back to the oldisPRModerule.classifyReviewOutcomeinapps/pi-extension/review-outcome.ts, which is added to the packagefileslist. The event API'scode-reviewresult declares the same field.legacyResult(stdout from an older CLI) never inferred the platform post. A status line from an older CLI still arrives as a feedback turn, as before. This is now noted in its doc comment.approvedand whether the body has content, not from the annotation count.Side effect: zero-annotation feedback (PR description, PR comment or editor comments only) now gets the request-changes suffix on the CLI, OpenCode and Pi. Before, it was delivered without the suffix, as if it were the status line.
Version skew: the client and the server ship together in each binary and package, so the flag is always present where it is needed. The OpenCode plugin and the CLI version independently, which is why the bridge has the fallback. Docs are updated in AGENTS.md: the host result file paragraph and the
/api/feedbackrow.Tests
apps/hook/server/host-result.test.ts: description-only, PR-comment-only and editor-only feedback with zero code annotations is delivered. The flagged platform post stays a no-op with the follow-up suggestion. An empty submit stays a no-op. One end-to-end case passes the real record through the mod'sdeliveryFor.apps/hook/server/review-output.test.ts: CLI output for each case.apps/opencode-plugin/commands.test.tsandapps/opencode-plugin/cli-bridge.test.ts: the embedded command and the bridge, including the older-CLI fallback.apps/pi-extension/review-outcome.test.ts: Pi delivery through the real Pi review server.packages/server/review-platform-flag.test.ts: both runtimes carry the flag only for a booleantrue("true",1and{}are dropped).packages/review-editor/App.decisionControl.test.tsx(DOM, already listed in CI): the platform status post sendsplatform: true, and agent-path feedback does not send the field.Run locally:
bun teston apps/hook, apps/opencode-plugin, apps/pi-extension, packages/server, packages/review-editor and packages/shared: all pass.bun run typecheck: passes.check:manifest: pass.scripts/test-claude-code-mod.shwith a temporaryCLAUDE_CONFIG_DIR(a fresh directory holding only a seeded.claude.json): 15 pass.Follow-up: binaries from 0.28.0 to 0.28.3
The Claude Code plugin updates from main separately from the binary. A 0.28.0 to 0.28.3 CLI still writes
platform: true, noop: truefor feedback with zero code annotations. The mod now treats a review record as the platform post only when its message is one of the editor's status lines:Pull request|Merge request approved|reviewed on …orChanges requested on …, the shapesstatusMessagebuilds in App.tsx. Any other non-emptyplatformrecord is delivered as review feedback (misreadAsPlatformPostinapps/hook/hooks/mod/delivery.ts). A CLI with this fix setsplatformonly on the real status post, which always matches, so it never takes this path. This is documented under "Version skew" in AGENTS.md.New tests in
delivery.test.ts:platform: trueis delivered.platform: trueis logged.Wording fix: only the Claude Code mod logs the status post. OpenCode, Pi, CLI stdout and Amp deliver it verbatim, without the request-changes suffix. The App.tsx comment and the
/api/feedbackrow in AGENTS.md now say this.