Expand description
On-disk state schema types per design.md §1.
Structs§
- Child
Ref (child_run_id, child_node_id)pointer recorded inNode::children.- Discussion
discussions/<discussion-id>.json(design.md §1.5).- Discussion
Id - A validated discussion identifier:
d-followed by exactly one of the two canonical bodies a generator emits — a 26-char lowercase Crockford base32 ULID (d-<ulid>) or a 10-char RFC 4648 base32 lowercase string (d-<sha-prefix>, the deterministic-id form). Seeis_canonical_disc_or_proposal_body. - Event
- One event-log line (design.md §1.4).
- Manifest
manifest.json(design.md §1.2).- Node
nodes/<node-id>.json(design.md §1.3).- NodeId
- A validated node identifier:
n-followed by 4 or more ASCII digits (e.g.n-0001). Mirrors whatcrate::format_node_idemits. - Proposal
Id - A validated spin-off proposal identifier:
s-followed by exactly one of the two canonical bodies a generator emits — a 26-char lowercase Crockford base32 ULID (s-<ulid>) or a 10-char RFC 4648 base32 lowercase string (s-<sha-prefix>, the deterministic-id form). Seeis_canonical_disc_or_proposal_body. - RunId
- A validated run identifier: a lowercase ULID (26 Crockford base32
characters whose first character keeps the encoded timestamp within
ULID’s 48-bit range). Mirrors what
crate::new_run_idemits. - Spinoff
Proposal spinoffs/<proposal-id>.json(design.md §1.5).- Tmux
Identity - A fully-qualified tmux window identity recorded at spawn time.
Enums§
- Discussion
Status - Discussion lifecycle status (design.md §1.5).
- IdValidation
Error - Error returned when a typed identifier fails parse-time validation.
- Kind
- The run/node kind enum (design.md §1.2).
- Lifecycle
- Lifecycle (design.md §1.2, §7.4).
- Spinoff
Status - Spin-off proposal status (design.md §1.5, §7.3).
- Status
- Run/node status (design.md §1.2).
Constants§
- STATE_
SCHEMA_ VERSION - The current state-on-disk schema version this crate writes.
- SUPPORTED_
STATE_ SCHEMAS - All state-schema versions this crate can read.
Functions§
- is_
run_ id_ prefix - True iff
sis a syntactically valid (possibly partial) prefix of aRunId: non-empty, no longer than a full ULID, every character a lowercase Crockford base32 digit, and a first character within ULID’s0..=7timestamp bound. Used by the CLI to resolve an unambiguous run-id prefix (likegit) — a value failing this is a malformed argument (invalid_run_id), not a legitimate-but-unknown prefix. The first-char bound is enforced because no validRunIdcan begin outside0..=7, so an8…/9…prefix is impossible rather than merely absent — reporting it as malformed keeps the error class honest and consistent with howRunId::parse_strrejects a full-length id with the same leading digit.