deepseek-harness/examples/headless-agent/tests
Hypatia May b341155652 feat(session): project the inherited-history boundary into the log
A plugin owning a standalone open/close bracket cannot tell a dead marker
from a live one: an unmatched `compact/start` reads identically whether the
previous writer died mid-compaction or a compaction is running now.
`Session.firstLiveSeq` already holds that answer exactly, but only in memory.

Append the log-only `session/inherited` event at that seq from the seeded
constructor — the single waist all six seeded-start paths pass through
(resume, configured startup on a persisted id, `sessions.fork()`, a subagent
fork child, `adopt()`'s live prefix, and a bare seeded `create`). Read it
through the new `isInheritedSeq(events, seq)`.

The constructor placement means persistence needs no changes: the marker is
already in `events` when a backend captures the creation seed, so it rides
the ordinary seed path with no load-time write. It also covers fork, where
the inherited bracket's owner may still be running — the case a
persistence-layer boundary could not reach.

Activity ordering excludes the boundary through `lastActivityTime()`, since
lazy resume makes browsing a pickup and the three call sites would otherwise
float every opened session to the top of a picker or list.
2026-07-30 11:39:26 +08:00
..
fixtures Merge remote-tracking branch 'origin/master' into feature/subagent-policy-inheritance 2026-07-28 11:19:46 +08:00
semantic-checkpoint-snapshots/tool-outcome-unknown feat(session): project the inherited-history boundary into the log 2026-07-30 11:39:26 +08:00
snapshots test(snapshot): preserve cwd punctuation 2026-07-29 00:02:38 +08:00
subagent-inheritance-snapshots/parent-override feat(session): project the inherited-history boundary into the log 2026-07-30 11:39:26 +08:00
code-mode.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
coding-task.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
compaction.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
full-loop.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
harness.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
headless.snapshot.ts test(snapshot): canonicalize generated cwd tokens 2026-07-28 23:46:01 +08:00
keyless-smoke.e2e.ts feat(persistence): compress JSONL logs with Zstandard 2026-07-20 00:06:21 +08:00
real-model.e2e.ts fix(examples): isolate headless agent example 2026-07-16 16:12:27 +08:00
resume.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
semantic-checkpoint.snapshot.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00
subagent-inheritance.snapshot.ts subagent: seed inherited policy events at creation 2026-07-28 21:31:17 +08:00
todo-write.e2e.ts refactor: identify and freeze messages at creation 2026-07-28 13:55:59 +08:00