Skip to content

feat(impact): whole-project value track credited from full fallow runs#812

Merged
BartWaardenburg merged 1 commit into
mainfrom
feat/impact-full-repo-track
May 30, 2026
Merged

feat(impact): whole-project value track credited from full fallow runs#812
BartWaardenburg merged 1 commit into
mainfrom
feat/impact-full-repo-track

Conversation

@BartWaardenburg
Copy link
Copy Markdown
Collaborator

Summary

  • Add a separate whole-project Impact track (project_records) recorded best-effort at the end of a full fallow run, kept apart from the changed-file audit track so the two scopes never share a trend.
  • Introduce Scope::ChangedFiles | WholeProject attribution: audit credits changed-file fixes; a full run additionally credits duplication and whole-repo cleanups fixed outside a changed-file audit (scope is the union of frontier keys plus this-run finding and clone paths).
  • Gate the project writer airtight in is_whole_project_run: it records only on a true whole-repo run (check + dupes + health, no --changed-since / --workspace / --changed-workspaces, no active diff filter, no production mode). A reshaped clone that is still duplicated under a new fingerprint is not falsely credited resolved.
  • ImpactReport gains optional project_surfacing / project_trend (additive; report schema_version stays 1). Human and markdown render an understated whole-project section labelled as whole-repo context, not a to-do, with an "advances only on local full runs, not CI" caveat.
  • Regenerate the MCP impact tool description, JSON schema, and TS contracts for the new fields.

Test plan

  • cargo test --workspace --all-targets: zero failures (pre-push gate green).
  • New render-state unit tests cover project-only and both-tracks rendering in human + markdown.
  • Attribution safety tests (resolved / suppressed / reshaped-clone) use real temp files so frontier pruning is exercised.
  • cargo clippy --workspace --all-targets -- -D warnings clean; cargo fmt --all -- --check clean.
  • OLD vs NEW smoke: a full fallow run accrues the project track; --only dupes, --changed-since, --production, and --diff-stdin all keep project_records empty; the actionable-vs-context labels render correctly in the release binary.

@BartWaardenburg BartWaardenburg enabled auto-merge May 30, 2026 18:03
Add a separate whole-project Impact track recorded best-effort at the
end of a full fallow run, kept apart from the changed-file audit track
so the two scopes never share a trend. A full run also credits
duplication and whole-repo cleanups fixed outside a changed-file audit.

The writer is gated airtight so it records only on a true whole-repo run
(check + dupes + health, no scope-narrowing flags, no diff filter, no
production mode). A reshaped clone still duplicated under a new
fingerprint is not falsely credited resolved. ImpactReport gains
optional project_surfacing and project_trend (report schema_version
stays 1); human and markdown render an understated whole-project
section labelled context, not a to-do.
@BartWaardenburg BartWaardenburg force-pushed the feat/impact-full-repo-track branch from 345e58e to a5a2a7b Compare May 30, 2026 20:25
@BartWaardenburg BartWaardenburg added this pull request to the merge queue May 30, 2026
Merged via the queue into main with commit 238ca29 May 30, 2026
34 checks passed
@BartWaardenburg BartWaardenburg deleted the feat/impact-full-repo-track branch May 30, 2026 20:45
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.

1 participant