Skip to content

feat(review): render single-line ```suggestion block on inline comments #2139

Description

@JSONbored

Render an InlineFinding's suggestion as a GitHub native single-line ```suggestion block appended to the inline comment body, so a contributor can commit the fix in one click. Single-line only (the finding's anchored RIGHT-side line); multi-line ranges are a separate slice.

Deliverables

  • Extend formatInlineBody (src/review/inline-comments.ts:71) to append a fenced suggestion\n<text>\n block when finding.suggestion is set
  • Keep public-safe: the suggestion text is already filtered by composeInlineFindings before it reaches here
  • No block when suggestion is absent (behavior byte-identical to today)
  • Tests: with/without suggestion (both branches), fence formatting, multi-line suggestion text preserved verbatim, severity label still leads the body

References

  • src/review/inline-comments.ts:71
  • src/review/inline-comments.ts:94
  • part of #1956

Part of #1956.


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

    Status
    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions