Skip to content

Promote Develop: Prose Gate Pin, Agent-Safety Launcher Probe, Kit Install on Release, Cleanup and Handoff Fixes - #4039

Merged
ptr727 merged 10 commits into
mainfrom
develop
Nov 10, 2026
Merged

ptr727 merged 10 commits into
mainfrom
develop

Conversation

@ptr727

@ptr727 ptr727 commented Nov 10, 2026 •

Copy link
Copy Markdown
Owner

Summary

Promotes burndown round 1 of the attended run of 2026-11-10 from develop to main.

Closes

Fixes #4033
Fixes #3935
Fixes #1172
Fixes #3783
Fixes #3897
Fixes #4019
Fixes #4009
Fixes #4013
Fixes #3679
Fixes #4018
Fixes #3914
Fixes #3841
Fixes #4017
Fixes #4010
Fixes #3791
Fixes #3795

🤖 Generated with Claude Code

ptr727 and others added 5 commits November 10, 2026 09:27
…tern, and Pin It Exactly (#4035)

## Summary

The prose gate crashed on import under markdown-it-py 4.3.0, so every
open pull request's Lint and Python unit-test jobs failed. In 4.2.0,
`markdown_it.common.html_re.HTML_TAG_RE.pattern` opens with `^`. In
4.3.0 it opens directly with its non-capturing group. `MARKDOWN_SPAN`
was built from `HTML_TAG_RE.pattern[1:]`. Under 4.3.0 that slice cut the
group's opening parenthesis, and the compile raised `re.PatternError:
nothing to repeat`.

- `.github/actions/prose-gate/prose_lint.py`:
- The span is now built by `markdown_span()`, which drops a leading `^`
only where one is present. The tag alternative is therefore the same
under 4.2.0 and 4.3.0. The rest of the upstream pattern is unchanged
between the two releases.
  - The inline dependency is pinned exactly, `markdown-it-py==4.3.0`.
- `scripts/backlog_metrics.py` takes #3935's first done-when option. It
pins `markdown-it-py==4.3.0` exactly, and also `mdurl==0.1.2`, the one
package that version requires. A run holding a `gh` token then imports
only versions this pull request reviewed. The usage header says that
running it with `--script`, as its documented command already does, is
what makes uv read those pins. It also says what a bump has to move.
- `tests/requirements.txt` takes the same exact markdown-it-py version,
so the suite runs the version the two pinned scripts run.
- `tests/test_prose_lint.py` checks a constructed tag pattern in both
shapes, anchored and unanchored. It asserts that the old one-character
slice fails to compile on the unanchored shape, and that
`markdown_span()` masks the same spans from either shape.
- `tests/test_backlog_metrics.py` adds `PinTests`:
- The markdown-it-py pin must be exact and equal across the prose gate,
`backlog_metrics.py`, and `tests/requirements.txt`.
  - Every dependency `backlog_metrics.py` declares must be exact.
- Each package the installed, pinned markdown-it-py requires must be
among those exact pins.

## Verification

- On import under markdown-it-py 4.3.0, the `develop` copy of
`prose_lint.py` raises `re.PatternError: nothing to repeat`.
- `test_prose_lint` and `test_backlog_metrics` pass under 4.2.0 and
under 4.3.0.
- The full unit-test suite passes under `tests/requirements.txt`: 3770
tests, 11 skipped.
- Each `PinTests` case fails when its condition is broken. A
`tests/requirements.txt` pin that differs from the other two fails the
first case. Dropping `mdurl` from `backlog_metrics.py` fails the last.
- `uv run --no-project --script scripts/backlog_metrics.py --help`
resolves the pins and runs.
- `scripts/prose_lint.py --diff` against `develop` reports nothing.

## Open introduced findings

- `tests/test_backlog_metrics.py`,
`PinTests.test_every_package_the_token_holding_run_resolves_is_pinned_exactly`
(class `introduced`): the test reads the requirements of markdown-it-py
alone, one level down. It does not read the requirements of the other
exact pins. So a future mdurl release that declares a requirement,
followed by a bump of the `mdurl==` pin, would leave that new package
unpinned with the test still green. The local pass's edit budget ran out
on this one, so this pull request's review loop decides its outcome.
- **Outcome: declined.** mdurl 0.1.2 declares no requirements, so no
package goes unpinned today. The gap opens only if two things happen: a
later mdurl release adds a requirement, and its pin is then bumped. That
bump is a reviewed one-line change, and the docstring tells whoever
makes it to pin what the new version requires. The suggested check also
could not measure the pin as written. `tests/requirements.txt` does not
pin mdurl, so the suite's installed mdurl is whichever 0.1.x uv
resolves, not the `backlog_metrics.py` pin. Making that check measure
the pin would mean a fourth stated pin with an equality test of its own.
That adds complexity for a case no current release produces.

## Declined review output

- CodeRabbit's "Docstring Coverage" pre-merge check (class `style`, on
`tests/test_backlog_metrics.py` `PinTests`), declined. No repository
rule requires a docstring on every function. The Python code-style
reference allows a one-liner, or none, on a trivial helper or a test
with a self-documenting name. This file's existing helpers, `issue` and
`metrics`, carry none. Each `PinTests` case's contract is in its name
and its class docstring.

Closes on promotion: #4033, #3935

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
…rs Through One Helper (#4032)

Closes on promotion: #1172, #3783

## Summary

Two maintainer-approved agent-safety fixes, one in the installer and one
in the write guard. Merging waits on the maintainer's go-ahead after
reading this diff, since it edits `host-setup/agent-safety/`.

### #1172: run the hook launcher before trusting it (approved Option 1)

- `install.py` no longer picks the interpreter it writes into
`settings.json` by presence on `PATH`. `launcher_problem()` runs each
candidate with a probe that must print a token and its version, and
refuses one below the 3.11 floor. Its stderr is kept in the reason. A
stub that exits 0, such as a Windows app execution alias, prints
neither, so it is refused.
- `hook_launcher()` tries `python3`, then `sys.executable`, and returns
the reasons each refused candidate failed. The install chooses the
launcher before writing anything, prints each candidate it passed over,
and installs nothing when none passes.
- Each hook's self-test now runs under that launcher rather than
`sys.executable`, so a pass also proves the launcher runs the hook.
- `--report` runs the launcher each registration names in the
`<launcher> <path>` shape, through `registered_launcher()`. So a host
registered before this fix reports STALE once that launcher stops
running. Any other command shape is not run.
- `install.sh` reads its probe's output against the 3.11 floor rather
than its exit status, and no longer discards the probe's stderr.

### #3783: read short-option clusters through one helper (approved
design "one shared helper, extended to separated values")

- `_cluster(word, values, optional)` returns a cluster's letters before
its first value-taking letter, and whether the value is the next word
(only where that letter ends the word). `_flags(sub, args)` walks a
subcommand's words through it, with `_OPTION_VALUES` holding each
subcommand's value letters, optional-value letters, and value-taking
long options.
- `_push_targets`, `_skips_hooks` (commit and push), the in-place commit
check, the primary-checkout `clean` reader, and the `git branch` rename
check all read through it. So do the other cluster readers in the same
file, per the one-primitive-per-class rule: the forced `worktree
remove`, the `checkout`/`switch` force check, the `rebase` operand
count, and the `symbolic-ref` write check. The old `_commit_flags`,
`_operands`, `_REBASE_VALUES`, `_CHECKOUT_FORCE_CHARS`, and the inline
regexes are gone. The guard is 2431 lines, under its 2500-line ceiling.
- The `clean` reader now skips the value after `-e` and `--exclude`,
attached or separated. So `clean -fen`, `-fe.env`, `-f -e -n`, and `-f
--exclude -n` are read as forcing, as git reads them, and are denied in
a primary checkout.
- Commit's `-S` and `-u`, branch's `-t`, and rebase's `-S` take an
attached value only, as git parses them. So `commit -Snkey` and `commit
-uno` carry no `-n`, and `branch -umain` is not a rename. A `rebase -x`
or `symbolic-ref -m` value is no longer counted as an operand, and
`symbolic-ref -qd` is read as a delete. These changes deny less only
where git itself reads no such flag.

## Verification

- `gh-write-guard.py --selftest` passes with new rows for each case
above, including the in-place `commit -Sa` (allowed) and `-aS` (denied)
and `symbolic-ref -- HEAD refs/heads/develop` (still a branch move).
Against develop's guard the new rows fail for `-Snkey`, `push -o
--no-verify`, `branch -umain`, `branch -u -m`, and the four `clean`
exclude forms.
- Each `clean` row was checked against git itself in a throwaway
repository: the four exclude forms delete an untracked file and `-f -e x
-n` keeps it.
- `test_install.py` passes, with a new `TestLauncher` class covering a
stub exiting 0, a stub failing with stderr, a version below the floor, a
missing launcher, the fallback past a broken `python3`, no working
candidate, an install refusing with nothing written, an install past a
broken `python3`, and `--report` flagging a registered launcher that
cannot run.
- ruff format, ruff check, mypy, shellcheck, shfmt, the prose gate, and
the eol check pass. `tests/test_guard_size.py` passes.

## Local strict review

Three recorded `agent-skill` passes. The first raised four findings, the
second two, and the third none. Each `introduced` finding was fixed on
this branch.

## Pre-existing findings, filed

- `host-setup/agent-safety/claude/install.ps1`, correctness: the Windows
wrapper takes `python3` because `Get-Command` finds it rather than
because it runs. Filed as #4031.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
…nd-release (#4029)

## Summary

Two edits to the `merge-and-release` skill, regenerated into both
distributions per `skill-lifecycle`.

- **Step 7 installs the updated host-safety kit.** Where the kit's
`--report` reads anything other than CURRENT, the step runs
`host-setup/agent-safety/claude/install.py` with no arguments from the
same detached `origin/main` worktree. It then runs `--report` again and
confirms CURRENT. A failed install, or a second report still not
CURRENT, is reported with its output and never retried. A seat that may
not run the installer reports that rather than working around it. The
step never edits the kit's files or the machine's settings by hand.
Where the install ran, the step reports that sessions need a restart.
The description, "Why This Exists", "How Far to Go", and "What Invoking
This Skill Authorizes" now name the kit install as part of the hub's
release scope.
- **Rollback guard.** The kit's `--report` compares payload digests
only, so a machine running a kit newer than `main` also reads stale. A
typical case is a kit installed from `develop`. So the step installs
only where the stamp's `hub` commit is clean and `origin/main` already
contains it, or where the report reads NOT INSTALLED. Any other case is
reported to the maintainer and left as it is.
- **Step 2 looks, then asks, when the promotion is already merged under
a release scope.** It reads `releaseTrigger` as step 5 does. It then
reads the publisher's runs on the full merge SHA and reports whether a
release started. A failed read is reported rather than taken as no
release started. A run found there is never dispatched again. Where none
started, it asks the maintainer before dispatching, and names `main`'s
tip if it has moved past the merge commit. The full SHA is required
because `gh run list --commit` given the digest's 8-character
`merge_commit=` matches no run, which would read as no release started.

## Introduced findings from the opening push

The local pass on the opening push raised these after its edit budget
was spent. Both were on the away-mode sentence in step 2, and both were
fixed in 35f6014. Under an away-mode grant, step 2 now only files the
`decision` issue and leaves acting on its answer to the maintainer,
since no step starts from an issue. Only an attended yes runs steps 5
and 6. The pass over that push recorded no findings.

- `.agents/skills/merge-and-release/SKILL.md:84-85`, `introduced`,
fixed: a yes recorded on the away-mode `decision` issue named no way for
a later session to start steps 5 and 6.
- `.agents/skills/merge-and-release/SKILL.md:84-87`, `introduced`,
fixed: acting on that yes later re-read only `main`'s tip, and not the
publisher's runs or the named merge SHA.

Closes on promotion: #3897, #4019

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
## Summary

`scripts/pr_cleanup.py` judged a worktree clean with `git status
--porcelain --untracked-files=all`, which never lists ignored files. It
then removed the worktree with `git worktree remove`, which refuses
tracked and untracked changes but deletes ignored files without asking.
A merged worktree holding an ignored `local.env` lost it with no
message, through `cleanup <number>` and `cleanup --sweep --apply` alike.

The fix takes the issue's second option and names the ignored entries
before removing them. The first option, refusing, was built and then
dropped after the local pass. A lint or test run leaves ignored caches
such as `__pycache__/` and `.ruff_cache/` in nearly every tree, and .NET
builds leave `bin/` and `obj/`. So a refusal blocked the default
post-merge cleanup on almost every real worktree, and no documented step
could clear it.

- `cleanup_status()` replaces `cleanup_dirty()`. One `git status
--porcelain -z --untracked-files=all --ignored=matching` read answers
both whether the tree has changes and which ignored entries it holds. An
ignored directory counts as one entry, which keeps the list short enough
to name every entry.
- `cleanup_remove_worktree()`, which every removal goes through, prints
`removing worktree <path> deleting its git-ignored <entries>` before a
removal that deletes any. It also prints the moved-shell note itself
now, so each caller drops its copy of both. That keeps `pr_cleanup.py`
under the 1200-line ceiling `tests/test_pr_review_size.py` holds.
- `cleanup --sweep` names the entries at the end of the worktree's
`would-remove` line in the report, before any `--apply`.
- `repo-worktree` "Listing and Cleanup" and `scripts/README.md`
"`pr_cleanup.py`" now say this. The skill's hand-removal path now reads
`git status --porcelain --ignored` before `git worktree remove`. The
generated skill copies are regenerated with `scripts/build_dist.py`.

## Verification

- `tests/test_pr_cleanup.py`: 110 tests pass. Run against the unfixed
script, the first four new cases failed, three as failures and one as an
error. They cover the status read telling changes apart from ignored
entries, including the directory entry and a list naming every entry.
They also cover a numbered cleanup naming the file before its removal,
and a sweep naming it both in the report and before an `--apply`
removal. A fifth case covers a detached worktree in the sweep, and a
sixth the moved-shell note the sweep prints when the shell stood in the
removed worktree.
- `ruff format --check`, `ruff check`, `mypy`, the prose gate,
`repo_gate.py --check eol`, and `build_dist.py --check` pass.

## Local review dispositions

- A local pass asked for one status read rather than two wrappers. That
is fixed.
- A local pass found the docs promised every ignored entry while the
code capped the list at five. The cap is gone, so every entry is named.
- A local pass found no case covering the ignored-entry note on a
detached worktree's sweep lines. One now does, in both modes.
- A local pass asked `cleanup_status()` to reuse `git_status_records()`
in `scripts/carry.py`. Declined: that helper reads without
`--no-optional-locks`, which the sweep's age rule needs. Its `--ignored`
mode with `--untracked-files=all` also lists every file inside an
ignored directory rather than the directory. Making it fit means editing
`carry.py`, which is outside this pull request's file claim.
- A local pass named three sibling hand removals that still run `git
worktree remove` on a tree judged only clean. They are in
`backlog-burndown` "Dispatching a Worker", `backlog-burndown` "Away
Mode", and `merge-and-release` "The Procedure". All three are declined
under `GOVERNANCE.md` "Trust Boundaries and Hardening Effort". Each tree
they remove is one an agent session created for its own worker or
installer run. The ignored content such a tree can realistically hold is
tool output rebuilt on demand, so the loss is neither realistic nor
destructive. They are outside this pull request's file claim.
- A local pass found the moved-shell note, now printed before the
caller's `removed worktree` line, saying "that worktree" with no
referent. It names the path now, and both removal paths' tests read it.
- A local pass noted one `pr_cleanup.py` docstring line past 100 columns
after a reflow. Declined as `style`: no gate enforces docstring width,
and `ruff check` passes.
- A local pass noted the `removing worktree` line prints unindented
inside the local half's two-space-indented progress lines. Declined as
`style`: the line is a progress message no consumer parses, and its text
and order are what the tests pin.

Closes on promotion: #4009

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
…Write a Final Round Before close (#4034)

## Summary

Fixes three `session-handoff` defects and decisions, in the skill and in
`scripts/handoff.py`.

- **A quoted round mark is no longer read as an archived round (#4013
item 1).** `rounds_of` now goes through a new `round_mark()`. A comment
counts as a round only when it carries exactly one mark and its first
line is the `## Round <n>, closed <date>:` heading `archive` writes,
naming the same round and date. The heading is parsed once, in a new
`ROUND_HEADING`, which `archived_text` shares. A round a writer edited
below its mark still reads. The "Resuming" comment filter checks the
same shape. It uses `capture` rather than backreferences, since `gh
--jq` runs gojq on Go's RE2. A writer's answer that quotes an example
mark now reaches the resuming session. A quote naming the outgoing round
no longer makes `new` refuse.
- **`blocked` stays on while a new decision waits (#4013 item 2).** "The
Attended Session" step 6 leaves the label on where a `decision` issue
the session filed on the link's work is still unanswered. The session
names that issue in a comment on the handoff. `GOVERNANCE.md` "Durable
Knowledge and Self-Improvement" is aligned, and the `agent-conduct`
include is regenerated.
- **`scripts/README.md`'s handoff.py section** now states the same whole
archived-round shape.
- **A default handoff pick is always confirmed (#3679, decided
2026-11-02).** Step 1 puts a link it picked with none named to the
maintainer as a prompt before any work, whatever its `updatedAt`. There
is no time window.
- **A track's last session writes a final round before `close` (#4018,
decided 2026-11-10, option 1).** "Closing a Session" step 2 writes it
with `new` where the session has anything for "What not to repeat" or
"New learnings". That keeps those findable by `chain --grep`. The
"Running the Chain" `close` bullet, which an away-mode lane close
follows, and the platform-lane close both point at that step.

## Verification

- `tests/test_handoff.py` passes (176 tests). The new test
`test_a_writer_s_comment_quoting_a_round_mark_is_no_round` uses
constructed comments and fails on develop's `handoff.py`.
- The filter was run under jq 1.8 against constructed comments: a quote
mid-comment, first, and last, a heading naming another round, two marks,
and an archived round in LF and CRLF. It was also run through `gh --jq`
against a live handoff issue, where it hid the archived rounds and kept
the ordinary comment.
- `build_dist.py --check` is current. The pre-commit gates (ruff, mypy,
prose lint, eol) pass.

Closes on promotion: #4013, #3679, #4018

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Copilot AI lite review requested due to automatic review settings November 10, 2026 18:26
@coderabbitai

coderabbitai Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • 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

… Configs, and Keep a Manual Findings Section (#4037)

## Summary

Three audit fixes in `spec/audit.py` and the docs that describe it.

- **Content is read at the head commit the tree was listed at (#3841).**
`Run.ref` is the head commit SHA `audit_repo` resolved. `Run.read_text`,
the baseline file reads, the intent last-change lookup, and the
Dependabot and cspell reads now pass it in place of the branch name. A
push landing mid-run can no longer 404 a path the tree listed and turn
the repository's result into one ERROR. Findings still name the branch.
- **The rendered reviewer configs are accepted gaps (#3914).**
`.coderabbit.yaml`, `.github/agent-policy.json`, and `.pr_agent.toml`
get `accepted` entries in `spec/divergences.json` `gaps`, so the
hub-only check stops asking for their deletion. A gap entry fits where a
`spec/files.json` declaration does not. `repo-config/configure.sh`
renders the policy per repository and sets derived values inside each
repository's own reviewer files, so no manifest fidelity describes them.
A baseline entry would also make the audit compare text that
`configure.sh check` already judges.
- **A convergence issue keeps a hand-written Manual findings section
(#4017, option 1).** `audit.py --issue` now ends its body at a fixed `##
Manual findings` heading. The generated intro says to replace only the
text above that heading when regenerating. The title's count now reads
as detected findings, since the hand-written section can hold deltas the
count never sees. `AUDIT.md` section 8 and the `audit-a-repo` skill say
a hand-judged finding goes there and regenerating keeps the section. No
`--manual` input was added, per the decision.

## Verification

- `tests/test_audit.py`: a constructed repository whose listed files 404
at the branch name still audits with no ERROR, and every content read
names the head commit. Both tests fail with the read pointed back at the
branch name. The three rendered configs held by a carrier report no
hub-only finding, and that test fails with the ledger entries removed.
- `tests/test_audit_helpers.py`: both the clean and the non-clean issue
body end at the single `## Manual findings` heading.
- `test_audit`, `test_audit_helpers`, `test_fidelity_honesty`,
`test_spec_validate`, `test_build_dist`, `test_prose_lint`,
`test_central_config`, `test_canonical_review`, `test_repo_gate`,
`spec/validate.py`, `spec/audit.py --selftest`, `build_dist.py --check`,
ruff, mypy, and the prose gate all pass locally.

Closes on promotion: #3914, #3841, #4017

🤖 Generated with [Claude Code](https://claude.com/claude-code)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Improvements**
* Repository audits now evaluate files against the same commit,
improving consistency when repository content changes during an audit.
* Audits better handle files that move or are rendered locally, reducing
incorrect findings about missing repository content.
* Generated audit issues now show the number of detected findings and
include a dedicated section for manually judged findings. Regenerating
an issue preserves that section.
* **Documentation**
* Clarified where to record manual findings and what regeneration
preserves.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>

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

Active moderate and critical findings leave malformed probe handling, Windows launcher parsing, and probe failure detection unresolved.

3 open issues
What changed in this PR

This promotion consolidates fixes for dependency pinning, host-safety installation, cleanup reporting, short-option parsing, and session handoff reliability.

Changes:

  • Pins Markdown dependencies and updates prose-gate compatibility tests.
  • Validates hook launchers, improves Git option parsing, and installs the current host-safety kit during release.
  • Reports ignored files before worktree removal and improves handoff archival and lifecycle handling.
  • Aligns governance, release procedures, and generated skill distributions with the updated behavior.
File Description
tests/​test_prose_lint.py Tests anchored and unanchored Markdown HTML patterns.
tests/​test_pr_cleanup.py Tests ignored-file reporting and worktree cleanup behavior.
tests/​test_handoff.py Tests round-marker parsing and archived-round handling.
tests/​test_backlog_metrics.py Tests exact dependency pin consistency.
tests/​requirements.txt Pins the prose parser dependency used by the tests.
scripts/​README.md Documents cleanup and handoff behavior.
scripts/​pr_cleanup.py Reports ignored entries before removing worktrees.
scripts/​handoff.py Validates complete archived-round marker shapes.
scripts/​backlog_metrics.py Pins runtime script dependencies exactly.
host-setup/​agent-safety/​README.md Documents updated short-option parsing behavior.
host-setup/​agent-safety/​claude/​test_install.py Tests launcher probing, fallback selection, and registration reporting.
host-setup/​agent-safety/​claude/​README.md Documents launcher validation and reporting behavior.
host-setup/​agent-safety/​claude/​install.sh Probes Python launchers before installation.
host-setup/​agent-safety/​claude/​install.py Validates launchers and registered hook commands before installation and reporting.
host-setup/​agent-safety/​claude/​gh-write-guard.py Centralizes short-option cluster parsing.
GOVERNANCE.md Aligns handoff blocking guidance with the implementation.
.github/​skills/​session-handoff/​SKILL.md Updates the generated session-handoff procedure.
.github/​skills/​repo-worktree/​SKILL.md Documents ignored-file cleanup behavior.
.github/​skills/​merge-and-release/​SKILL.md Adds release-time host-safety installation guidance.
.github/​skills/​agent-conduct/​SKILL.md Updates generated blocking guidance.
.github/​actions/​prose-gate/​prose_lint.py Updated as part of this pull request.
.claude-plugin/​fleet-skills/​skills/​session-handoff/​SKILL.md Regenerates the Claude session-handoff skill.
.claude-plugin/​fleet-skills/​skills/​repo-worktree/​SKILL.md Regenerates the Claude worktree skill.
.claude-plugin/​fleet-skills/​skills/​merge-and-release/​SKILL.md Regenerates the Claude release skill.
.claude-plugin/​fleet-skills/​skills/​agent-conduct/​SKILL.md Regenerates the Claude conduct skill.
.claude-plugin/​fleet-skills/​.source-digests/​session-handoff Updates the generated session-handoff skill digest.
.claude-plugin/​fleet-skills/​.source-digests/​repo-worktree Updates the generated worktree skill digest.
.claude-plugin/​fleet-skills/​.source-digests/​merge-and-release Updates the generated release skill digest.
.claude-plugin/​fleet-skills/​.source-digests/​agent-conduct Updates the generated conduct skill digest.
.agents/​skills/​session-handoff/​SKILL.md Updates the canonical handoff lifecycle rules.
.agents/​skills/​repo-worktree/​SKILL.md Updates the canonical ignored-file cleanup rules.
.agents/​skills/​merge-and-release/​SKILL.md Adds release-time host-safety installation guidance.
.agents/​skills/​agent-conduct/​SKILL.md Updates the canonical blocked-handoff guidance.

Review effort: Lite

…e Committing (#4036)

## Summary

The `git-commit-conventions` signing probe commits in a fresh scratch
repository, so it reads only the system and global git config. A target
repository with its own `commit.gpgsign=false`, or its own `user.email`,
passed the probe. Its commit then landed unsigned or under another
address.

"Identity, verified not set" now adds a read-only check. It runs in each
target repository before the session's first commit there. It refuses a
path outside any repository. It compares `user.email`, `author.email`,
`committer.email`, `user.signingkey`, `commit.gpgsign`, and `gpg.format`
there against what a fresh repository reads, and prints each value's
scope and origin. Any `DIFFERS` line means stop at `git add` and tell
the maintainer about it as the host fault the section already names. The
report names the setting and its scope, and keeps the raw line out of
posted text, since that line holds observed host data. The agent neither
removes the override nor commits past it with `-c`. The check comes in a
one-line sh form and a PowerShell form.

The signing bullet's claim that every fleet branch rejects an unsigned
push is corrected. Only the `develop` and `main` rulesets require
signatures, per `repo-config/develop.json` and `repo-config/main.json`.
The bullet now names both checks as what catches an unsigned commit on a
feature branch.

The scratch probe itself is unchanged. So its copies in `STANDUP.md` and
`docs/host-setup.md`, which check the host rather than a target
repository, stay byte-identical with it.

## Verification

- Constructed cases, both forms: a fresh repository with local
`commit.gpgsign=false` and `[email protected]` prints
`DIFFERS` for those keys with scope `local` and exits non-zero. A local
`[email protected]` does the same for that key. A
directory outside any repository is refused. A fresh repository with no
local settings prints `same` for every key and exits zero.
- `shellcheck -s sh` is clean on the sh form.
- `build_dist.py --check` is current, and the pre-commit gates pass.
- Three recorded `local-strict-review` passes. The first raised seven
findings, the second one, and the third none.

## Local review findings declined

- `.agents/skills/git-commit-conventions/SKILL.md` target-repository
check, `introduced`: the values are compared as raw strings, so
`commit.gpgsign=yes` beside a global `true` reads `DIFFERS`. Declined:
the input is the maintainer's own config, and the failure is a loud
spurious stop, never a silent pass. So the trust-boundaries rule gives
it no fix.
- Same check, `introduced`: `config --show-scope` needs git 2.26 or
later. Declined: on an older git only the provenance column is blank,
and the verdict and the stop are unaffected.

## Dropped findings

- `STANDUP.md` override check after `git init`, consolidation: a
narrower local-only form of the same check. It runs on a freshly
initialized repository and is followed by verifying the real first
commit's signature and identity, so it is not in disagreement with this
change.

Closes on promotion: #4010

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
@codecov

codecov Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 66.66667% with 35 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.03%. Comparing base (4670daa) to head (9b277fc).
⚠️ Report is 487 commits behind head on main.

Files with missing lines Patch % Lines
host-setup/agent-safety/claude/gh-write-guard.py 15.00% 34 Missing ⚠️
scripts/pr_cleanup.py 96.29% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4039      +/-   ##
==========================================
+ Coverage   78.76%   79.03%   +0.26%     
==========================================
  Files          37       37              
  Lines       12680    12676       -4     
==========================================
+ Hits         9988    10019      +31     
+ Misses       2692     2657      -35     
Flag Coverage Δ
python-3.13 79.03% <66.66%> (+0.26%) ⬆️

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.

… Workspace (#4038)

## Summary

- Moves the .NET workspace resolver out of `validate-task.yml`, where
the `lint` and `unit-test` jobs each carried a copy, into a new hub
composite action, `.github/actions/dotnet-workspaces`. Both jobs reach
it through `$/` and pass it their own project pathspec, and the style
job also asks for solutions. Each dotnet step reads the action's
`workspaces` output through an env var. An empty list is the bare call.
- Keeps the bare call only where the repository root holds exactly one
`.sln`, `.slnx` or `.csproj`. A root holding more than one now takes the
#1938 naming rule, per the 2026-11-02 maintainer answer on #3795: each
tracked solution for the style step (each project where the tree holds
none), and each `*Tests*.csproj` by `--project` for the test step. This
covers an `App.sln` left beside the `App.slnx` that `dotnet sln migrate`
writes, two root projects, and a root solution beside a root project,
each of which failed both steps before, since a bare call resolves
exactly one workspace.
- Updates `WORKFLOW.md` D1.6 to state the exactly-one rule, and
regenerates the `workflow-ci-contract` include that carries it.
- Fixes item 2 of #1259: removes the header summary block at the top of
`validate-task.yml`. Nothing replaces it, since each input already
carries its own description. Item 1 of #1259 belongs to #1270 and is not
in this change. The root `README.md` drops its claim that this header
names every job.
- `tests/test_release_guards.py`: retires the test asserting the two
resolver copies were identical. The per-workspace test now runs the
action's resolver step with the inputs each job passes it, then feeds
its output to that job's dotnet step against a stand-in `dotnet`. It
also checks each job's wiring: same `if:` on the resolver and its
consumer, and the consumer reading that resolver's output. An input a
job leaves out takes the default the action itself declares. It adds the
three multi-workspace root cases and a single root project case. The
no-report test now passes an empty workspace list rather than building a
git tree.

The action is bash in `action.yml` with no script beside it, so it needs
no registration elsewhere. The repo gate's `composite-actions` check
reads it, and `.github/actionlint.yaml`'s existing `$/` ignore for
`validate-task.yml` covers the new `uses:`.

Closes on promotion: #3791, #3795

## Introduced findings answered in the review loop

- `README.md:162`, `introduced`: the sentence calling
`validate-task.yml` the validator "whose header names every job it runs"
turned false once this change removed that header. Raised by the third
local pass, after the opening push's two-round edit budget was spent.
Fixed in c27c0c1 by dropping that clause, and a fourth local pass over
the result raised nothing.

## Verification

- `python -m unittest discover -s tests`: all pass.
- A mutation check on the new test: dropping the more-than-one root
branch from the action fails the three new cases. Passing `solutions:
'false'` from the lint job fails the solutions cases. Changing the
action's `solutions` default to `'true'` fails the test step's cases.
- `scripts/docker_lint.py` (editorconfig-checker, actionlint,
markdownlint, cspell, shellcheck, shfmt, PSScriptAnalyzer): success.
- `scripts/repo_gate.py`, every check: 0 issues, the `composite-actions`
check reading 12 action files.
- Prose gate over the branch diff: no violations. `build_dist.py
--check`: current. ruff format and check, and mypy: clean.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
…Status (#4041)

## Summary

Fixes two of the three P1 findings raised on promotion PR #4039 against
the agent-safety launcher probe that #4032 added. Each fix fails closed,
and each comes with a test built on constructed input that fails against
the code on `develop`.

- `host-setup/agent-safety/claude/install.py:498` (`launcher_problem`):
a probe that printed the token followed by a non-numeric version, such
as `agent-safety-launcher 3a 11`, raised `ValueError` and aborted the
install or `--report`. That output is now a refusal, so
`hook_launcher()` moves on to the next candidate.
- `host-setup/agent-safety/claude/install.sh:16`: the wrapper ignored
the probe's exit status, so a stub that printed `ok` and exited 3 was
handed `install.py`. The output is now captured with an `&&` status
check before it is compared. The exposure was narrower than the finding
states, because `install.py`'s own `hook_launcher()` already re-probes
the hook launcher and checks its return code. What was at stake is only
which interpreter runs `install.py`.

## Deferred finding

- `host-setup/agent-safety/claude/install.py:530`
(`registered_launcher`) is deferred to #4040, on the maintainer's
decision. For the double-quoted shape `hook_command()` writes, the
finding is wrong: POSIX `shlex.split` keeps single backslashes, so a
quoted `C:\...` launcher splits intact. A UNC launcher loses one of its
leading backslashes inside double quotes, and a bare, unquoted
hand-written path loses all of them. Whether either of those is a defect
depends on which shell runs a hook on native Windows. Under Git Bash the
POSIX split matches what actually runs, and under cmd.exe it does not.
#4040 settles the executor before the split changes.

## Tests

New cases in `TestLauncher` in
`host-setup/agent-safety/claude/test_install.py`:

- `test_a_malformed_version_is_refused_and_the_next_candidate_tried`:
before the fix it raised `ValueError: invalid literal for int() with
base 10: '3a'`.
- `test_install_sh_passes_over_a_python_that_prints_ok_and_fails`: runs
`install.sh --help` with a `python3` stub that prints `ok` and exits 3,
placed ahead of a working `python`. Before the fix the wrapper exits 3.

`python3 -m unittest test_install` runs 196 tests, all OK. `shellcheck
install.sh`, `ruff check`, and `ruff format --check` are clean.

## Local review findings, declined

- The local pass judged both fixes over-hardening, saying only a stub
written for a test reaches the non-integer branch or prints `ok` while
failing. Declined: both are P1 findings verified real on #4039 with
constructed inputs, the maintainer kept them, and each fix fails closed
in a few lines.

A later local pass found that the new `install.sh` test's skip condition
carried a redundant `os.name` check. That is fixed in this PR.

## Pre-existing findings, not filed

- `host-setup/agent-safety/claude/install.ps1`, the Windows twin of
`install.sh`, which this PR does not touch, chooses `py -3` or `python3`
without running a version probe. A `python3` app execution alias would
be picked and would then fail loudly through `exit $LASTEXITCODE` rather
than fall through to the next candidate. `install.py` still enforces the
3.11 floor on its own.

Closes on promotion: none

🤖 Generated with [Claude Code](https://claude.com/claude-code)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved installation checks for Python launchers. Invalid version
information and checks that fail despite printing a success message are
now rejected, allowing the installer to try another candidate and avoid
creating an incomplete installation.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>

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

A critical workspace-resolution issue remains in .github/actions/dotnet-workspaces/action.yml, allowing the style job to silently omit root projects when nested solutions coexist.

1 open issue
3 resolved since last review

Review effort: Lite

@ptr727

ptr727 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@ptr727

ptr727 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

/review

@coderabbitai

coderabbitai Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

…ed Solution (#4042)

## Summary

Fixes the finding raised on promotion #4039 against
`.github/actions/dotnet-workspaces/action.yml:40-46`.

Where the repository root tracked more than one `.sln`, `.slnx` or
`.csproj` and the caller asked for solutions, the action named every
nested solution and never the root's own entries. A tree holding
`App.csproj`, `AppTests.csproj`, `sub/Tool.sln` and `sub/Tool.csproj`
resolved to `sub/Tool.sln` alone. So the lint job's `dotnet format
style` passed while skipping both root projects, a fail-open style
check.

- `.github/actions/dotnet-workspaces/action.yml`: a root holding more
than one entry is now resolved as a unit. With `solutions: 'true'`, it
names only the root's own solutions. Where the root holds none, it falls
back to the `projects` pathspec, as before. Nested solutions are named
only where the root holds nothing. The `solutions` input's description
states the rule.
- The exactly-one rule #3795 decided is unchanged. A root holding
exactly one solution or project still takes the bare call. The test
step, which passes no `solutions`, is unchanged too, so `WORKFLOW.md`
D1.6, which describes only that step, still matches and is not edited.
- `tests/test_release_guards.py`: the per-workspace test gains two
layouts, two root projects beside a nested solution and two root
solutions beside a nested solution. Both fail on develop's action and
pass on this one. The existing cases are kept.

Closes on promotion: none

## Verification

- `python -m unittest discover -s tests`: all 3784 pass (11 skipped),
run with `tests/requirements.txt` installed as CI does.
- Mutation check: with develop's `action.yml` restored, the two new
layouts fail the style step's case and every other case passes.
- `scripts/repo_gate.py`: exit 0.
- `scripts/docker_lint.py`: success, 7 linters.
- Prose gate over the branch diff: no violations.
- Two recorded local strict passes. The first raised two `introduced`
wording findings, the input description and the test docstring each
stating the rule for every root rather than one holding more than one
entry. Both are fixed in 5cc9352, and the second pass raised nothing.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>

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.

🔵 Needs a closer look

Human approval is still needed because the host-safety installer, native Windows launcher behavior, live hook registration, and release-time workflow remain unexecuted in review.

No open issues 🎉

1 resolved since last review

Review effort: Lite

@ptr727

ptr727 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

Answering the verdict headline of the Copilot round on 9b277fcc, which counts no finding (0):

Human approval is still needed because the host-safety installer, native Windows launcher behavior, live hook registration, and release-time workflow remain unexecuted in review.

No change needed. The headline names no defect and no failing input. It names surfaces a review cannot execute. The two concrete installer defects round 1 raised were fixed in a735c0a (#4041), which added cases to host-setup/agent-safety/claude/test_install.py. The native-Windows registration shapes a review could not settle are tracked in #4040. The human approval it asks for is the maintainer's permission to merge this promotion, which this pull request is waiting on in any case.

@ptr727

ptr727 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

Merge Gate item 2, promotion case, at head 9b277fcc (recorded before the merge, 2026-11-10).

Copilot's Lite tables name 33 of this promotion's 55 changed files, so they are not the coverage. Each of the ten constituent feature PRs (#4035, #4032, #4029, #4030, #4034, #4037, #4036, #4038, #4041, #4042) carries a local-review attestation by the owner. The marker sits on its own line, on base develop, at the PR's final merged head. Every one of the 55 files in origin/main..origin/develop was mapped to the squash commit that last changed it. Each file is in that commit's PR diff, which the PR's attestation covers. No file is uncovered.

The maintainer gave the merge-and-release go-ahead for this head.

@ptr727
ptr727 merged commit 1397e30 into main Nov 10, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment