Skip to content

Solution for long term memory for agent coding CLIs and to facilitate handoff between different agent vendors

Rust

Merge PR #725: extend native session-id state file to ZCode

AkitaOnRailsfb28fabf3c2a
diff --cc CHANGELOG.md
index 53b7d8e1,a19f54b4..dbf4aa68
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@@ -7,19 -7,22 +7,38 @@@ and this project adheres to [Semantic V
## [Unreleased]
+### Security
+- Updated `rustls` 0.23.40 → 0.23.45 for [RUSTSEC-2026-0285](https://rustsec.org/advisories/RUSTSEC-2026-0285),
+ in which a TLS 1.3 handshake message that follows a key-changing message in
+ the same record can be accepted at the wrong encryption level. `rustls` is a
+ direct dependency — it installs the process-wide crypto provider the MCP
+ bridge needs for HTTPS — and is also the TLS implementation every outbound
+ HTTPS call resolves to through reqwest, so the advisory failed `cargo audit`
+ and `cargo deny check` on every open pull request that inherited `main`'s
+ lockfile, including ones that change no Rust at all. `Cargo.toml` already
+ allows compatible 0.23 patch releases, so this is a lockfile-only change
+ needing no manifest or public-surface edit; the same resolution moves
+ `rustls-webpki` 0.103.13 → 0.103.15 and nothing else (#731).
+
+ ### Fixed
+ - The native `ai-memory hook` session-id state file
+ (`<data_dir>/hook-state/<agent>-session-id`), introduced for Devin in #178,
+ now also covers ZCode. ZCode's hook payloads do not reliably carry a session
+ id, it fires `Stop` at the end of every turn, and it has no `SessionEnd`
+ event — without a persisted id, each turn with an id-less payload opened a
+ fresh server-side session that nothing ever closed (observed in production:
+ 4 sessions with NULL `ended_at` and 398 observations stuck in episodic).
+ ZCode events without a native id now share one stable stored id per agent
+ session; events carrying a native id are passed through untouched. The stored
+ id is cleared by `finalize-session --agent zcode` (which now also removes the
+ state file) or overwritten by the next `session-start`; `Stop` never clears
+ it. Other agents are unaffected: payloads that carry a session id short-circuit
+ the state file exactly as before.
-
++- `memory_feedback`'s `signal` (FeedbackKind) JSON schema now declares a
++ top-level `type: "string"`, so strict function-calling gateways (Moonshot/Kimi
++ and other schema validators) accept the `tools/list` surface instead of
++ rejecting the enum for a missing type (#735, #741).
+
## [2.2.1] - 2026-09-12
### Fixed