Repository navigation
fix(#1782): skip review stage on closed PR or skipped author - #1783
Conversation
|
/fs-fix-stop |
|
Fix agent disabled for this PR. Remove the |
|
🤖 Finished Review · Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $0.24 This review was superseded by a newer commit. Check the current pull request HEAD's review status before merging. |
|
🤖 Finished Review · Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $0.29 This review was superseded by a newer commit. Check the current pull request HEAD's review status before merging. |
pre-review.src.sh exited 0 after posting a "Review skipped" comment for closed/merged PRs and for authors in REVIEW_SKIP_AUTHORS, but never wrote the pre-script output protocol skip signal. fullsend run therefore still created the sandbox and ran the review agent, and post-review's own closed-PR guard posted a second "Review skipped" comment. Source lib/prescript-output.lib.sh (as pre-code.src.sh does) and write skipped=true plus a single-line reason on both skip exits before exiting 0. Under a CLI that predates the protocol the variable is unset and prescript_output is a no-op, so behavior is unchanged there. Regenerate the bundled scripts/pre-review.sh. pre-review-test.sh gains protocol tests: closed/merged PRs and skipped authors (incl. case/whitespace variants) write the exact skip lines; an open PR and the no-token path leave the file empty; with FULLSEND_PRESCRIPT_OUTPUT unset both skip paths still comment and exit 0. Note: `pre-commit run` could not fetch hook repos in the sandbox (TLS error); the configured hooks (pre-commit-hooks v6.0.0, shellcheck v0.10.0.1, lint-release-cases) were run directly and passed, and gitleaks was covered by scan-secrets. The four fixture-00x projection tests in pre-review-test.sh fail in the sandbox because yq is not installed; they fail identically on main. Closes #1782 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Assisted-by: Claude Signed-off-by: Wayne Sun <gsun@redhat.com>
Assisted-by: Claude Signed-off-by: Wayne Sun <gsun@redhat.com>
5beeb79 to
c22dc88
Compare
|
🤖 Finished Review · ✅ Success · Started 8:02 PM UTC · Completed 8:23 PM UTC Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $1.63 |
|
<!-- fullsend:risk-assessment --> DetailsModerate risk change modifying protected pre-review scripts without a feature flag and touching churned files, balanced by small diff size, full acceptance criteria alignment, and bot authorship. |
ReviewFindingsMedium
|
waynesun09
left a comment
There was a problem hiding this comment.
Approving at c22dc88: pre-review's closed/merged and skip-author exits now emit the pre-script skip, so no sandbox starts; behaviour run 40127849705 passed 11/11 and the reject scenario dropped from ~440 s to 332 s. Protected path (scripts/) human-approved here.
The reject scenario's second /fs-review round only checked that the review workflow succeeded and posted the "Review skipped" comment. Both hold whether or not the agent ran, so the scenario could not prove that pre-review stopped the stage (fixed in fullsend-ai#1783). Bump github.com/fullsend-ai/fullsend to main 3ea9dd1b8 (fullsend-ai/fullsend#8793, for fullsend-ai/fullsend#8792), which adds the step "the harness <agent> run was skipped by its pre-script". It reads the run's host telemetry for fullsend.prescript.skipped=true and requires no agent output. Add it after the second round's workflow step. The old pin's go.sum entries are replaced, matching previous bumps; fullsend's go.mod hash is unchanged. Verification: the behaviour package vets and compiles against the new pin with the CI-style -modfile replace setup, and the new line matches the registered step regex. harness/triggertest passes. Live behaviour scenarios could not run in the sandbox. make cannot run here (sandbox blocks /bin/sh); running the script-test commands directly gives the same 15 environment-only failures on main and on this branch. skillsaw --strict passed. pre-commit could not fetch hook repos; pre-commit-hooks v6.0.0 checks and lint-release-cases run directly passed, and scan-secrets (gitleaks) passed. Closes fullsend-ai#1784 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Summary
Changes in
scripts/pre-review.src.sh(and the regenerated bundlescripts/pre-review.sh): both early skip exits now emit the pre-script output protocol skip signal, sofullsend runstops before creating the sandbox:skipped=trueandreason=PR #<n> is already <state>REVIEW_SKIP_AUTHORS: writesskipped=trueandreason=PR author <author> is in REVIEW_SKIP_AUTHORS(the author goes through_gha_sanitize, which strips newlines, so the reason stays on one line)Before this change both paths posted a "Review skipped" comment and then ran
exit 0without the signal. The review agent still ran (about 4 minutes plus model spend), and on closed PRs post-review's own guard posted a second "Review skipped" comment.The script now sources
lib/prescript-output.lib.sh, aspre-code.src.shdoes. With a CLI that predates the protocol,FULLSEND_PRESCRIPT_OUTPUTis unset andprescript_outputdoes nothing, so behavior there is unchanged.Behaviour change on upgrade
REVIEW_SKIP_AUTHORSnow gets no agent review at all, asdocs/review.mddescribes. Before, the agent still reviewed it, so an approval could re-addready-for-merge.Testing
New protocol tests in
scripts/pre-review-test.sh:skipped=trueplus the reason lineskipped=trueplus the reason lineFULLSEND_PRESCRIPT_OUTPUTunset, both skip paths still exit 0, print the skip notice and post the commentAll new tests pass. shellcheck (v0.10.0.1, repo args) and the pre-commit-hooks v6.0.0 checks were run directly on the changed files and pass;
pre-commit runitself couldn't fetch hook repos in the sandbox because of a TLS error. The bundledpre-review.shwas regenerated withscripts/bundle-sh.sh.Caveats
fixture-00x-*-projectiontests inpre-review-test.shfail in the sandbox becauseyqisn't installed. They fail the same way onmainand are unrelated to this change.make script-testand thebehavioursuite could not run in the sandbox (makecouldn't spawn/bin/sh) and need to be checked in CI.🤖 Generated with Claude Code
Closes #1782
Post-script verification
agent/1782-pre-review-skip-signal)372c909351b43d71d23e7d95978ebe607a3ddcfa..HEAD)