@lace-cloud/canvas 0.24.0 → 0.26.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/README.md +15 -7
- package/dist/{chunk-HZWABSPP.mjs → chunk-ID563WHD.mjs} +795 -583
- package/dist/chunk-ID563WHD.mjs.map +1 -0
- package/dist/engine/index.cjs +784 -580
- package/dist/engine/index.cjs.map +1 -1
- package/dist/engine/index.d.mts +2 -2
- package/dist/engine/index.d.ts +2 -2
- package/dist/engine/index.mjs +5 -1
- package/dist/index.cjs +1261 -962
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +3 -9
- package/dist/index.d.ts +3 -9
- package/dist/index.mjs +333 -242
- package/dist/index.mjs.map +1 -1
- package/dist/{mapping-Z-STJQRP.d.mts → registry-BhFAgvlq.d.mts} +96 -16
- package/dist/{mapping-Z-STJQRP.d.ts → registry-BhFAgvlq.d.ts} +96 -16
- package/package.json +3 -3
- package/dist/chunk-HZWABSPP.mjs.map +0 -1
package/README.md
CHANGED
|
@@ -75,6 +75,11 @@ if (apply) await runner.run(apply, { root, stack }, {});
|
|
|
75
75
|
// results.getSnapshot().run is the run's phases, last log line and outcome.
|
|
76
76
|
```
|
|
77
77
|
|
|
78
|
+
A command that failed says why as data (`CommandExitError.failure`), and
|
|
79
|
+
`answering(CORE_COMMAND_ACTIONS, failure)` is what a host offers on it:
|
|
80
|
+
the actions that answer that failure's reason (Import the rest answers
|
|
81
|
+
`import_residual`), each run the same way with `{ failure }` as its target.
|
|
82
|
+
|
|
78
83
|
A host that mounts the canvas can own its result store too: pass it as
|
|
79
84
|
`<App ports={ports} results={results} />` and call `results.bumpTick()`
|
|
80
85
|
when something outside the canvas changed what `stack describe` reports
|
|
@@ -122,8 +127,9 @@ const { ports, close } = await openEngineSession(caller, { root: '/path/to/autho
|
|
|
122
127
|
iterable throws it). Every `source` frame names the
|
|
123
128
|
tree the session last observed (`treeHash`), and a subscriber that
|
|
124
129
|
passes `onCommandResult` receives the result of every command that ran
|
|
125
|
-
in the session's root, the last per command path replayed
|
|
126
|
-
late — the input of `foldReport`,
|
|
130
|
+
in the session's root, the last per command path replayed in the order
|
|
131
|
+
they were published when it joins late — the input of `foldReport`,
|
|
132
|
+
whose `currentReport` keeps the
|
|
127
133
|
entries about that tree. The stream's end reaches every
|
|
128
134
|
`source` subscriber as `{ kind: 'closed' }` — the session is gone — or
|
|
129
135
|
`{ kind: 'failed', error }` — the stream is gone and the session
|
|
@@ -138,11 +144,13 @@ const { ports, close } = await openEngineSession(caller, { root: '/path/to/autho
|
|
|
138
144
|
`Invocation.cancel()` sends `CancelInvoke`
|
|
139
145
|
only and leaves `events` running until the command's own exit — a
|
|
140
146
|
`signal` abort or `close()` detaches the stream instead, without
|
|
141
|
-
cancelling the command's remote effects. An `Invoke` stream that
|
|
142
|
-
before the command's exit rejects `events` with
|
|
143
|
-
when the consumer's `signal` aborted
|
|
144
|
-
|
|
145
|
-
and
|
|
147
|
+
cancelling the command's remote effects. An `Invoke` stream that stops
|
|
148
|
+
before the command's exit, by an end or an error, rejects `events` with
|
|
149
|
+
`CommandDetachedError` when the consumer's `signal` aborted; otherwise
|
|
150
|
+
with `CommandUnobservedError` once the engine sent `started` (it
|
|
151
|
+
accepted the request and runs the command, so the command ran and its
|
|
152
|
+
outcome never arrived), and with the call's own error before it (the
|
|
153
|
+
command never ran).
|
|
146
154
|
- `openEngineCommands(caller, { cwd })` is the commands mapping:
|
|
147
155
|
`Initialize` once, `Invoke` per command, no session and no Subscribe.
|
|
148
156
|
- Both mappings name the protocol version this package speaks
|