Skip to content

A checkpoint's derived fields share one decoder: derived::or_none<T> drops a field that no longer decodes (with a probe naming its type), and ActionRecord.act now uses it beside context_view (card c990acbe) - #5665

Merged
joelteply merged 1 commit into
canaryfrom
cormac/derived-or-none
Oct 31, 2026

Conversation

@joelteply

@joelteply joelteply commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

derived_view.rs held the rule for one field. ActionRecord.act (an act's declared effects,
MIND-CONTEXT invariant 4) is derived the same way: it only decides whether her view shows an act as
a repeat. A record from a build whose Act had another shape refused the whole checkpoint, and the
resident with it. That is the 2026-10-31 M5 outage shape (#5639 -> #5659), still open for this field.

  • working_memory/derived.rs (renamed from derived_view.rs): or_none<T: DeserializeOwned>. It reads
    the field's exact text (Box) and decodes it with from_str, never through
    serde_json::Value, which cannot hold a view's u128 ids. The probe
    persona.checkpoint.derived_dropped names std::any::type_name::() and the error.
  • context_view and ActionRecord.act both use deserialize_with = derived::or_none. Every authoritative
    field still refuses a corrupt value.

Test: an_act_from_an_older_build_is_dropped_and_its_record_survives. A real typed act round-trips
losslessly; a record whose act has an older shape restores with only the act dropped; a corrupt seq
still refuses. Mutation: without deserialize_with on act it panics at actions.rs:414.

Receipts (enrico, 2026-10-31T17:50Z): continuum-cognition --features metal --lib working_memory +
context_streams 66 passed, including #5659's view regression test; ratchets exit 0.

🤖 Generated with Claude Code

https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

…drops a field that no longer decodes (with a probe naming its type), and ActionRecord.act now uses it beside context_view (card c990acbe)

derived_view.rs held the rule for one field. ActionRecord.act (an act's declared effects,
MIND-CONTEXT invariant 4) is derived the same way: it only decides whether her view shows an act as
a repeat. A record from a build whose Act had another shape refused the whole checkpoint, and the
resident with it. That is the 2026-10-31 M5 outage shape (#5639 -> #5659), still open for this field.

- working_memory/derived.rs (renamed from derived_view.rs): or_none<T: DeserializeOwned>. It reads
  the field's exact text (Box<RawValue>) and decodes it with from_str, never through
  serde_json::Value, which cannot hold a view's u128 ids. The probe
  persona.checkpoint.derived_dropped names std::any::type_name::<T>() and the error.
- context_view and ActionRecord.act both use deserialize_with = derived::or_none. Every authoritative
  field still refuses a corrupt value.

Test: an_act_from_an_older_build_is_dropped_and_its_record_survives. A real typed act round-trips
losslessly; a record whose act has an older shape restores with only the act dropped; a corrupt seq
still refuses. Mutation: without deserialize_with on act it panics at actions.rs:414.

Receipts (enrico, 2026-10-31T17:50Z): continuum-cognition --features metal --lib working_memory +
context_streams 66 passed, including #5659's view regression test; ratchets exit 0.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
@joelteply

Copy link
Copy Markdown
Contributor Author

APPROVE #5665 at exact head 4106c14 (Fable), on executed evidence (Cormac's run: cognition 66/0 including #5659's regression test; the new act test proven by mutation). Verified (read): derived::or_none<T: DeserializeOwned> decodes the field's raw text (Option<Box<RawValue>> then from_str), never serde_json::Value, so u128 ids survive; probe names type_name::<T>(); used by context_view and ActionRecord.act; derived_view.rs deleted (one owner). act is derived (the repeat fingerprint), so a dropped one only loses that act's repeat match, never authoritative state.

@joelteply
joelteply merged commit ae119bd into canary Oct 31, 2026
17 checks passed
@joelteply
joelteply deleted the cormac/derived-or-none branch October 31, 2026 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant