Artifacts: runner-internal turn files move to a Debugging files group

Each recorded artifact now carries a server group (deliverable or debug).
public/ files are deliverables; input/memory/history/output.md, session
exports and private/ scratch are debugging files. The app's Artifacts tab
lists deliverables and the Debug toggle reveals a separate Debugging files
group (older servers fall back to the filename rule); the TUI lists
deliverables first and marks debug rows; artifact search excludes debug
files unless include_debug / --debug-files is set.
This commit is contained in:
2026-11-04 17:43:47 +00:00
parent b5927505cc
commit 57f5219628
24 changed files with 541 additions and 30 deletions
+1 -1
View File
@@ -138,7 +138,7 @@ func (r *runner) scanArtifacts(runID int64, sequence int, directory string, publ
if len(files) == 0 {
files = nil
}
return files, skipped, truncated
return protocol.ClassifyArtifacts(files), skipped, truncated
}
// artifactRel returns the slash path of directory below the artifacts root. A
+10
View File
@@ -55,6 +55,13 @@ func TestSessionEvidenceIsInventoriedBeforeLargeCaptureDirectories(t *testing.T)
t.Fatalf("mandatory runtime file %s hidden by user captures", name)
}
}
// The recorded inventory carries the server's classification: turn files and
// private captures are debugging files.
for _, file := range files {
if file.Group != protocol.ArtifactGroupDebug {
t.Fatalf("%s group %q, want debug", file.Name, file.Group)
}
}
}
func TestArtifactsScanRecordsSizesTypesAndSkips(t *testing.T) {
@@ -396,6 +403,9 @@ func TestArtifactHTTPGetPublicSharedFile(t *testing.T) {
if shared.URL == "" {
t.Fatalf("public artifact missing: %+v", step.Artifacts)
}
if shared.Group != protocol.ArtifactGroupDeliverable {
t.Fatalf("public artifact group %q, want deliverable", shared.Group)
}
srv := httptest.NewServer(handler)
defer srv.Close()
resp, err := http.Get(srv.URL + shared.URL)