@womp/spark-agent 10.1.0 → 10.1.1
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 +13 -0
- package/dist/capabilities/flow-runs.js +10 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,19 @@ Notable changes to `@womp/spark-agent`, newest first. Versions follow
|
|
|
4
4
|
[Semantic Versioning](https://semver.org/). Add an entry with each version bump; describe what
|
|
5
5
|
changed for hosts and users, and how to migrate across breaking changes.
|
|
6
6
|
|
|
7
|
+
## 10.1.1 — 2026-10-13
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- `womp.flowRuns.wait(runId, seconds)` waits through the host's `waitForService`, outside the
|
|
12
|
+
60-second JavaScript budget. Before, `wait(runId, 60)` (the skill's own example) always ended
|
|
13
|
+
the call with "JavaScript exceeded 60 seconds." instead of returning the run's status. On a host
|
|
14
|
+
without `waitForService`, the wait is cut to 45 seconds.
|
|
15
|
+
|
|
16
|
+
### Migration
|
|
17
|
+
|
|
18
|
+
- None.
|
|
19
|
+
|
|
7
20
|
## 10.1.0 — 2026-10-13
|
|
8
21
|
|
|
9
22
|
### Added
|
|
@@ -2,6 +2,8 @@ import { z } from "zod";
|
|
|
2
2
|
import { WOMP_FLOW_RUNS_DECLARATIONS } from "../generated/flow-runs-declarations.js";
|
|
3
3
|
export const FLOW_RUN_WAIT_MAX_SECONDS = 60;
|
|
4
4
|
export const FLOW_RUN_WAIT_DEFAULT_SECONDS = 30;
|
|
5
|
+
/** A wait inside the 60 s JavaScript budget, on a host without waitForService, with room for the rest of the call. */
|
|
6
|
+
const FLOW_RUN_WAIT_INLINE_MAX_SECONDS = 45;
|
|
5
7
|
const runId = z
|
|
6
8
|
.string()
|
|
7
9
|
.regex(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i, "Use a runId returned by run().");
|
|
@@ -61,7 +63,14 @@ While a run is live on this project (not a copy run), womp.scene.access is refus
|
|
|
61
63
|
return start();
|
|
62
64
|
},
|
|
63
65
|
status: async (id) => host.status(runId.parse(id), context),
|
|
64
|
-
wait: async (id, seconds) =>
|
|
66
|
+
wait: async (id, seconds) => {
|
|
67
|
+
const parsed = runId.parse(id);
|
|
68
|
+
const bound = waitSeconds.parse(seconds);
|
|
69
|
+
// wait(id, 60) would spend the whole 60 s JavaScript budget; a service wait is outside it.
|
|
70
|
+
if (context.waitForService)
|
|
71
|
+
return context.waitForService("Waiting for the flow run", () => host.wait(parsed, bound, context));
|
|
72
|
+
return host.wait(parsed, Math.min(bound, FLOW_RUN_WAIT_INLINE_MAX_SECONDS), context);
|
|
73
|
+
},
|
|
65
74
|
cancel: async (id) => host.cancel(runId.parse(id), context),
|
|
66
75
|
deleteCopy: async (id) => {
|
|
67
76
|
context.signal.throwIfAborted();
|