Reviewer cohort reuse should tolerate inherently unassigned files
Problem
After a fresh review of yakshed PR 7, .github/workflows/ci.yml is intentionally reported by the normal coverage gate as unassigned because no current reviewer agent glob matches it. The saved cohort then makes every plain follow-up fail before reviewer execution with:
saved reviewer cohort leaves changed file ".github/workflows/ci.yml" uncovered; pass --fresh-session
Running --fresh-session selects the same catalog and cannot make the file coverable, so the guidance creates a loop and discards useful reviewer-session continuity.
Root cause
First-run selection permits files that match no selected agent to remain in the existing incomplete_unassigned coverage bucket. Cohort rebasing applies a stricter invariant: every changed file must be assigned to a saved member, even when no agent in the current catalog can match it. That makes later-run behavior inconsistent with first-run behavior.
Change
Keep the fixed-cohort contract and its useful incompatibility failures, but distinguish recoverable from inherent gaps while rebasing:
- Reassign new files to saved broad members or saved scoped members whose globs match, as today.
- If no saved member can take a file but another current catalog agent can match it, retain the terminal
--fresh-session guidance because reselection can help.
- If no current catalog agent can match the file, leave it unassigned and continue with the saved cohort. The existing reviewer-coverage gate remains authoritative and must report
incomplete_unassigned; this does not silently make approval eligible.
- Preserve saved reviewer ordering and provider-session reuse.
- Preserve failures for adapter/runtime incompatibility, missing cohort members, and undersized
--max-agents.
- Update the lifecycle documentation to describe the distinction.
TDD verification
- Add a failing rebase test with a saved scoped reviewer covering
main.go and an unmatched .github/workflows/ci.yml; expect successful cohort reuse with only main.go assigned.
- Prove the downstream coverage summary still contains an
unassigned entry for the workflow file.
- Add/retain a failing case where a catalog agent outside the saved cohort can match the newly uncovered file; expect
--fresh-session guidance.
- Run focused pipeline tests, race-sensitive tests if the changed path has concurrent state, and
make check.
Empirical definition of done
Build the combined candidate from draft PR #561. Using the established yakshed PR 6 and PR 7 cohorts, run normal non-posting follow-up reviews without --fresh-session:
- PR 6 completes without dossier process-vocabulary rejection.
- PR 7 completes without the saved-cohort uncovered-file terminal error, preserves reviewer reuse, and reports
.github/workflows/ci.yml through the ordinary unassigned coverage entry.
Both commands must exit successfully. No yakshed review is posted.
Delivery
Implement as a separate commit after 6c59cfb on draft PR #561. Update that PR to close this issue as well as #559. Run one independent TDD coverage assessment for the combined PR, the normal cr review loop, CI, and squash-merge only after both empirical gates pass.
Reviewer cohort reuse should tolerate inherently unassigned files
Problem
After a fresh review of yakshed PR 7,
.github/workflows/ci.ymlis intentionally reported by the normal coverage gate as unassigned because no current reviewer agent glob matches it. The saved cohort then makes every plain follow-up fail before reviewer execution with:saved reviewer cohort leaves changed file ".github/workflows/ci.yml" uncovered; pass --fresh-sessionRunning
--fresh-sessionselects the same catalog and cannot make the file coverable, so the guidance creates a loop and discards useful reviewer-session continuity.Root cause
First-run selection permits files that match no selected agent to remain in the existing
incomplete_unassignedcoverage bucket. Cohort rebasing applies a stricter invariant: every changed file must be assigned to a saved member, even when no agent in the current catalog can match it. That makes later-run behavior inconsistent with first-run behavior.Change
Keep the fixed-cohort contract and its useful incompatibility failures, but distinguish recoverable from inherent gaps while rebasing:
--fresh-sessionguidance because reselection can help.incomplete_unassigned; this does not silently make approval eligible.--max-agents.TDD verification
main.goand an unmatched.github/workflows/ci.yml; expect successful cohort reuse with onlymain.goassigned.unassignedentry for the workflow file.--fresh-sessionguidance.make check.Empirical definition of done
Build the combined candidate from draft PR #561. Using the established yakshed PR 6 and PR 7 cohorts, run normal non-posting follow-up reviews without
--fresh-session:.github/workflows/ci.ymlthrough the ordinary unassigned coverage entry.Both commands must exit successfully. No yakshed review is posted.
Delivery
Implement as a separate commit after
6c59cfbon draft PR #561. Update that PR to close this issue as well as #559. Run one independent TDD coverage assessment for the combined PR, the normalcrreview loop, CI, and squash-merge only after both empirical gates pass.