@volter/supercode-orchestrator 0.5.87 → 0.5.89
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/board/workflow.mjs +11 -8
- package/package.json +2 -2
package/board/workflow.mjs
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
// pane, sending a session a message, cleaning a workspace) is answered as effects the caller runs after commit.
|
|
7
7
|
import { current } from './call.mjs';
|
|
8
8
|
import { notRuntime } from './owner-files.mjs';
|
|
9
|
+
import { machineCall } from './doors.mjs';
|
|
9
10
|
import { execFile } from 'node:child_process';
|
|
10
11
|
import { promisify } from 'node:util';
|
|
11
12
|
import { existsSync, readdirSync, realpathSync, watch, readFileSync } from 'node:fs';
|
|
@@ -275,14 +276,16 @@ export async function refreshRelationAnswers(board) {
|
|
|
275
276
|
const id = json(row.payload, {})?.waiting_on; if (id) ids.add(id);
|
|
276
277
|
}
|
|
277
278
|
const list = [...ids];
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
279
|
+
if (!list.length) return;
|
|
280
|
+
// one read of this machine's daemon for every id (its header index answers, no process per message)
|
|
281
|
+
try {
|
|
282
|
+
const { rows } = await machineCall(null, 'harness.v1.mail.show', { ids: list, replies: true }, { timeoutMs: 20_000 });
|
|
283
|
+
if (!Array.isArray(rows)) throw new Error('the mail door returned no message list');
|
|
284
|
+
for (const id of list) {
|
|
285
|
+
const row = rows.find((item) => item?.id === id);
|
|
286
|
+
mailboxAnswers.set(id, { answer: row?.replies?.[0]?.id ?? null, askedOf: row?.session ?? null });
|
|
287
|
+
}
|
|
288
|
+
} catch (error) { for (const id of list) mailboxAnswers.set(id, { error: `the answer to ${id} could not be read: ${String(error.message).slice(0, 200)}` }); }
|
|
286
289
|
}
|
|
287
290
|
function answerTo(id) {
|
|
288
291
|
const observed = mailboxAnswers.get(id);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@volter/supercode-orchestrator",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.89",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "The orchestrator runtime over the Volter Harness ontology: one typed operational model whose folder is its serialization, read and written through the harness orchestration doors (docs/ORCHESTRATOR-IR.md)",
|
|
6
6
|
"exports": {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@volter/supercode-harness-sdk": "^0.3.60",
|
|
28
|
-
"@volter/teams": "0.2.
|
|
28
|
+
"@volter/teams": "0.2.33",
|
|
29
29
|
"@volter/ztrack": "^2.4.23",
|
|
30
30
|
"yaml": "^2.9.0"
|
|
31
31
|
},
|