Repository navigation
feat(core): finalize orphaned multi-process evidence runs - #134
Merged
Merged
Conversation
This was referenced Sep 9, 2026
Recover interrupted evidence when the owner process is dead, rebuild reports from the append-only journal, and add one session index for short-lived CLI and MCP processes. Journals stay in place and are never rewritten. Expose recovery on artifacts report and MCP artifact_report.
Unreadable /proc start times no longer reclaim a live owner. Corrupt journals keep their valid prefix. Completed runs stay read-only index inputs. Unknown action status is tolerated on reads. Artifact names may contain spaces. Invalid and disappeared runs are skipped with a reason.
…nvalid mid-recovery
ElbertePlinio
force-pushed
the
feat/110-finalize-orphaned-runs
branch
from
September 9, 2026 13:44
174292d to
e9d8f12
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Short-lived CLI, MCP, and DevTools processes against one browser session were leaving evidence runs
runningwithoutreport.html, even thoughactions.jsonlwas intact. After producers stop,pickforge-lab artifacts report --finalize-orphansand MCPartifact_reportwithfinalizeOrphans: truerecover those runs in the configured write root.Dead owners are detected from the session pointer. Interrupted runs are marked
orphanedrather than completed. Reports and artifact inventories are rebuilt from existing files and the journal. Each recovered session gets onesession-<sessionId>.htmlindex. Journals, run directories, and pointers are never rewritten, moved, or deleted. Torn tails stay on disk and are omitted from the report. A corrupt journal keeps its valid prefix and is labeledjournal: "corrupt"withactions: Nand a warning; a missing journal is labeled unavailable. Completed and failed runs with a report stay read-only inputs for the session index and are not stampedevidenceRecovery. Live owners, ambiguous pointers, invalid manifests, and disappeared run directories are skipped with a reason. Stale adopters cannot append to a recovered orphan. Layout claims and writes stay on verified descriptors from #91/#104/#109; recovery never creates a missing root.Known limits: pointers and locks do not record a hostname, so pid probes on shared storage are meaningless (pre-existing). Orphaned runs are never pruned by retention. Session index links can dangle after retention.
Closes #110
Validation on 222e824 in
/home/dev/Projects/.worktrees/picklab/feat-110-orphaned-runs:bun install --frozen-lockfile,bun run typecheck,bun run lint,bun run test(116 files, 1548 passed, 4 skipped),bun run build,complexity-gate check --changed(no violations).