@urun-sh/core 0.3.7 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,26 @@
1
1
  # Changelog
2
2
 
3
- ## Unreleased
3
+ ## 0.4.0
4
+
5
+ - **BREAKING: `SessionPhaseName` loses `'ended'` and `'expired'`** (#392, #398 —
6
+ session-semantics Phases 3 and 5; model: `urun-python/docs/design/session-semantics.md`).
7
+ A session is a named durable object: nothing the server sends ends it. Every
8
+ compute-release word (`closed`, `cancelled`, `canceled`, `releasing`, `released`,
9
+ `reaped`, `superseded`, `expired`) now maps to the NON-TERMINAL phase **`'paused'`**,
10
+ carrying the server's word as `reason`; `error` survives (a failed operation, not a
11
+ finished session) and no longer latches, so the same id attaches again freely.
12
+ `isTerminalPhaseName()` and the not-resumable verdict hook are deleted. Migration:
13
+ a `switch` over the phase name that handled `'ended'` / `'expired'` handles `'paused'`
14
+ instead and reads `reason` for the cause (`max_session_age`, `credits_exhausted`,
15
+ `idle_timeout`, …); copy that said "start a new session" is wrong under this model —
16
+ the conversation is still there.
17
+
18
+ - **New: the session directory** (#398). Discovery and attach are two mechanisms:
19
+ `sessionDirectory(app, opts)` lists / ends / archives / unarchives the caller's own
20
+ sessions (`SessionDirectory`, `SessionSummary`, `SessionState`), and
21
+ `app.fn(args, { sessionId })` resumes one by reference (or `{ label }` starts a new
22
+ named one). `session.detach()` releases the device; `session.end()` releases the
23
+ compute and parks the object. There is deliberately no `delete`.
4
24
 
5
25
  - **BREAKING: `WtMicUplinkHandle` and `WtCamUplinkHandle` require
6
26
  `deliveredDatagrams(): number`; `WtUplinkSink` requires `delivered(): number`.**