@theokit/sdk 3.1.0 → 3.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 +6 -0
- package/dist/a2a/index.cjs +14 -9
- package/dist/a2a/index.cjs.map +1 -1
- package/dist/a2a/index.js +14 -9
- package/dist/a2a/index.js.map +1 -1
- package/package.json +3 -3
package/dist/a2a/index.js
CHANGED
|
@@ -19198,15 +19198,20 @@ var MessageBus = class {
|
|
|
19198
19198
|
// SE3 — provenance projection of the sender address (thin view over `from`).
|
|
19199
19199
|
origin: { kind: "peer", from }
|
|
19200
19200
|
};
|
|
19201
|
-
|
|
19202
|
-
|
|
19203
|
-
|
|
19204
|
-
(
|
|
19205
|
-
|
|
19206
|
-
|
|
19207
|
-
|
|
19208
|
-
|
|
19209
|
-
|
|
19201
|
+
let timer;
|
|
19202
|
+
try {
|
|
19203
|
+
return await Promise.race([
|
|
19204
|
+
Promise.resolve(handler(message)),
|
|
19205
|
+
new Promise((_, reject) => {
|
|
19206
|
+
timer = setTimeout(
|
|
19207
|
+
() => reject(new Error(`A2A request timeout: ${to} did not respond within ${timeoutMs}ms`)),
|
|
19208
|
+
timeoutMs
|
|
19209
|
+
);
|
|
19210
|
+
})
|
|
19211
|
+
]);
|
|
19212
|
+
} finally {
|
|
19213
|
+
if (timer !== void 0) clearTimeout(timer);
|
|
19214
|
+
}
|
|
19210
19215
|
}
|
|
19211
19216
|
has(agentId) {
|
|
19212
19217
|
return this._handlers.has(agentId);
|