Publish outputs to checked destinations and preserve failure evidence

This commit is contained in:
2026-11-16 03:52:35 +00:00
parent cea7e44232
commit b63c8af467
11 changed files with 656 additions and 336 deletions

View File

@@ -34,12 +34,12 @@ func Markdown(snapshot Snapshot) []byte {
fmt.Fprintf(&b, "Recoveries: %s of %s model operations \n", showCount(snapshot.Summary.Recoveries), showCount(snapshot.Summary.LLMOperations))
fmt.Fprintf(&b, "Proposal responses: %s; with filtering: %s\n\n",
showCount(snapshot.Summary.ProposalResponses), showCount(snapshot.Summary.ProposalResponsesWithFiltering))
fmt.Fprintf(&b, "Transcript input: %s \n", escapeMarkdown(snapshot.TranscriptPath))
fmt.Fprintf(&b, "Transcript input: %s \n", stageCellEscaper.Replace(html.EscapeString(snapshot.TranscriptPath)))
output := snapshot.OutputPath
if output == "" {
output = "stdout"
}
fmt.Fprintf(&b, "Transcript output: %s\n\n", escapeMarkdown(output))
fmt.Fprintf(&b, "Transcript output: %s\n\n", stageCellEscaper.Replace(html.EscapeString(output)))
fmt.Fprintln(&b, "## Work-unit errors")
fmt.Fprintln(&b)

View File

@@ -119,6 +119,22 @@ func TestStageIDIsLiteralInMarkdownAndExactInYAML(t *testing.T) {
}
}
func TestMarkdownTreatsTranscriptPathsAsLiteralText(t *testing.T) {
snapshot := Snapshot{
TranscriptPath: "incoming/[raw](https://example.invalid)/_input_ <part>.json",
OutputPath: "out/*file*\\name\nsecond",
}
rendered := string(Markdown(snapshot))
for _, want := range []string{
`incoming/\[raw\](https&#58;//example.invalid)/\_input\_ &lt;part&gt;.json`,
`out/\*file\*&#92;name<br>second`,
} {
if !strings.Contains(rendered, want) {
t.Fatalf("missing escaped path %q in:\n%s", want, rendered)
}
}
}
func markdownTableRows(text string) []string {
var rows []string
for _, line := range strings.Split(text, "\n") {