Skip to content

feat(review): fix-handoff block renderer for review findings (boundary-safe, content-only) #2175

Description

@JSONbored

Core renderer for #1962: turn a single review finding into a structured, machine-readable 'apply this fix' block (path/line/description/suggested change) that a contributor's OWN local agent can consume. Content only — no server-side write, no execution. Default-OFF via config; public-safe by construction.

Deliverables

  • New src/review/fix-handoff.ts exporting a pure builder finding -> {path, line, severity, instruction, suggestedChange?} handoff block (accepts InlineFinding from src/services/ai-review.ts:215)
  • Machine-readable rendering (fenced block / HTML comment marker) mirroring the inline-comment body composition in src/review/inline-comments.ts:69
  • Explicit boundary note reusing LOCAL_WRITE_BOUNDARY from src/mcp/local-write-tools.ts:8
  • Fail-safe: a finding with no commentable line still yields a valid block (path-only)
  • Tests: with/without suggestedChange, with/without line, boundary text present, public-safe escaping (branch-counted)

References

  • src/mcp/local-write-tools.ts:8
  • src/services/ai-review.ts:215
  • src/review/inline-comments.ts:69

Part of #1962.


size: S · held for later release (gittensor:feature once activated)

Metadata

Metadata

Assignees

No one assigned

    Labels

    gittensor:featureGittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions