Skip to content

Bound Code Execution in the Local Strict Review Brief - #2879

Merged
ptr727 merged 8 commits into
developfrom
feature/review-execution-bound
Oct 12, 2026
Merged

ptr727 merged 8 commits into
developfrom
feature/review-execution-bound

Conversation

@ptr727

@ptr727 ptr727 commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

Summary

The local-strict-review brief said "read-only" but put no bound on running code. A reviewer that probes a script by running it still fits those words. A dev-loop script run that way builds environments and starts servers, and their gitignored artifacts leave git status clean.

  • fleet-code-review "Review the Change" is the single home for the rule and its reason:
    • Apart from reading files, git state, and the pull request, a review runs no command its requester does not name.
    • Running code is otherwise left to the author and CI, because even a --help run can build environments and start servers that git status misses.
    • A finding that only an unnamed command could prove still counts as supported once it names that command.
    • "Establish the Contract" item 4 now applies only to a check the requester names.
  • local-strict-review "Running It": the diff brief's Bounds line points at "Review the Change" and adds only the exact commands its Task line names. The sweep brief quotes "Review the Change" and so carries the same bound without restating it.
  • Regenerated .github/skills/ and .claude-plugin/ with scripts/build_dist.py.

Closes #2864

Local review

A local strict review pass was recorded before every push, and the last pass on this head found nothing. Earlier findings were disposed of as follows:

  • Fixed: the fallback cited "Publish Every Finding", a section the local briefs exclude. It now stands without that cross-reference.
  • Fixed: the brief's Bounds line restated the bound in different words. It is now a pointer that only adds commands to what "Review the Change" allows.
  • Declined: the finding that item 4 licenses running a check's documented invocation. Item 4 is a file read done before a named check is reported as skipped. It licenses no run, and the only run allowed stays the one the requester names.

Verification

  • python3 scripts/build_dist.py --check: current
  • python3 scripts/prose_lint.py . --diff <merge-base>, with and without --check sentence-length: clean
  • the full-tree prose_lint.py --check invocation from OPERATIONS.md: clean
  • python3 scripts/repo_gate.py, python3 spec/validate.py, python3 scripts/docker_lint.py: pass

🤖 Generated with Claude Code

A reviewer probing a dev-loop script by running it executes the real thing, building environments and starting servers whose gitignored artifacts leave git status clean, while the brief still reads as read-only. Both briefs now bound execution, and fleet-code-review states that executing the change belongs to its author.

Closes #2864
The first wording allowed any listed lint or type-check run without its exact invocation, bounded only code from the change, and implied a run with arguments was safe. The review skill's reason claimed author verification that an outside pull request lacks.
Read-only git and search commands left a shell-only reviewer no way to read a whole file. The dev-loop rationale overclaimed every argument, and the review skill's name-the-command sentence clashed with discarding an unsupported finding, so it moves into the local brief, which publishes nothing.
Copilot AI lite review requested due to automatic review settings October 12, 2026 16:20
@coderabbitai

coderabbitai Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0f0599bd-83c3-4320-ad78-24a891cb8262

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

Copilot AI left a comment

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.

🟡 Changes recommended

Two unresolved execution-boundary findings remain.

2 open findings
What changed in this PR

This PR bounds reviewer code execution and regenerates distributed skill copies.

Changes:

  • Restricts review execution to read-only or explicitly required commands.
  • Delegates normal code and test execution to authors and CI.
  • Regenerates GitHub and Claude skill distributions and source digests.
File Summary
.github/​skills/​local-strict-review/​SKILL.md Generated local-review skill
.github/​skills/​fleet-code-review/​SKILL.md Generated review skill
.claude-plugin/​fleet-skills/​skills/​local-strict-review/​SKILL.md Generated local-review skill
.claude-plugin/​fleet-skills/​skills/​fleet-code-review/​SKILL.md Generated review skill
.claude-plugin/​fleet-skills/​.source-digests/​local-strict-review Updated source digest
.claude-plugin/​fleet-skills/​.source-digests/​fleet-code-review Updated source digest
.agents/​skills/​local-strict-review/​SKILL.md Canonical execution bounds
.agents/​skills/​fleet-code-review/​SKILL.md Review execution policy

🧠 Review effort: Lite


💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .agents/skills/local-strict-review/SKILL.md Outdated
Comment thread .agents/skills/fleet-code-review/SKILL.md Outdated
The review skill's bound named only the change's code, so running an unchanged consumer of a changed config stayed allowed. The brief's exception read as any command the skill names, recording commands included. The sweep brief also gains the name-the-command fallback.
@codecov

codecov Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 59.93%. Comparing base (7061724) to head (6ecfdf6).
⚠️ Report is 2 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #2879   +/-   ##
========================================
  Coverage    59.93%   59.93%           
========================================
  Files           16       16           
  Lines         8627     8627           
========================================
  Hits          5171     5171           
  Misses        3456     3456           
Flag Coverage Δ
python-3.13 59.93% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

The review skill's bound named only repository code, left item 4 assuming the reviewer runs unnamed checks, and lacked the fallback both briefs restated, so an unprovable finding fell to discard-or-publish. The brief's reason no longer claims every run of a dev-loop script has side effects.
A probe is not a check, so the review rule now bounds every command beyond reading files, git state, and the pull request. A finding only an unnamed command could prove counts as supported once it names that command, so it no longer conflicts with discarding unsupported findings. The sweep brief relies on the quoted section rather than restating the bound.
@ptr727

ptr727 commented Oct 12, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head 58fafcbc900fc4e3efeb96f3dfb33389ca35db13, the content this pull request carries at that commit against develop, and it recorded 3 findings.

The brief's Bounds line restated the bound in different words, so it now points at Review the Change and adds only Task's exact commands. The reason moves into Review the Change, and the fallback no longer cites a section the local briefs exclude.
The pointer read as defining the whole allowance, which excluded the git reads the brief's own Paths line needs. The reason sentence now applies only outside the named commands.
@ptr727

ptr727 commented Oct 12, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head 6ecfdf6cd68ece9e3763f3fa97644c996984038e, the content this pull request carries at that commit against develop, and it recorded 0 findings.

@ptr727
ptr727 merged commit fc41694 into develop Oct 12, 2026
13 checks passed
@ptr727
ptr727 deleted the feature/review-execution-bound branch October 12, 2026 16:52
ptr727 added a commit that referenced this pull request Oct 12, 2026
…ounds, PurpleAir Rows, and the D7.1 Schedule Suffix to Main (#2884)

- #2878 exempts tool directive names from the comment-case rule
- #2880 isolates TestCli from the working directory and tests the
absolute-path diff floor
- #2879 bounds code execution in the local strict review brief
- #2881 ticks the homeassistant-purpleair rollout rows in Stages 1, 3,
and 4
- #2883 names the schedule run-id suffix in D7.1 and accepts it in the
audit

Closes #2828
Closes #2861
Closes #2862
Closes #2864
Closes #2875
Closes #2876

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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