3 months ago
93e72a2Maintainers can, per outcome (pass / block / sent-to-review), set custom
comment text that REPLACES the entire auto comment — headline, reasons,
remedies, and the how-to-fix / what-is-tripwire blocks — and toggle the
"View on Tripwire" details button. Together (custom text + button off) =
full opacity: the contributor gets the message and nothing to click.
Replacing the WHOLE body, not just the summary, is load-bearing: a naive
summary-only swap would strand the wait-hint / how-to-fix remedy and leak
the very rule the maintainer set out to hide. Tested against the real
rule strings — the custom body contains none of the evidence, remedy, or
fix text.
- storage: shared commentOverride { customText, showDetailsButton } on a
per-outcome key (block extends it; pass/review are their own objects).
Fully default-backed ("" / true) — an untouched repo renders identically,
no migration.
- generator: renderVerdictComment resolves the per-outcome override from
the full config; customText replaces the body, showDetailsButton drops
the run-page link. renderCommentBody keeps a default-true button param so
the locked snapshots stay byte-identical.
- ui: OutcomeComment (textarea + toggle) reveals under an outcome once it's
set to comment, matching the existing block-reveal pattern; the save
queue carries the new per-outcome keys.
- run view + markdown read the RESULT, not the comment, so replacing the
comment body never blanks the maintainer-facing evidence.
Legacy block shape modes are kept for back-compat; folding them into the
new custom-text override is tracked as TRP-81.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>Parent2924085