mindvest-atlas 0.9.1 → 0.9.2
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/package.json
CHANGED
|
@@ -97,7 +97,14 @@ async function answer(requestId, payload) {
|
|
|
97
97
|
* confined to the jobs folder: it can list what is there and show one file; it
|
|
98
98
|
* cannot write, delete, or reach outside. */
|
|
99
99
|
async function handleAsk(ask, root) {
|
|
100
|
+
// ADDRESSED TO ONE MACHINE. The ask channel is per-USER, so every computer
|
|
101
|
+
// this person owns hears every question. Fine for "list your files" — they
|
|
102
|
+
// each answer about themselves — but a BUILD must land on the machine they
|
|
103
|
+
// picked, not on whichever happens to reply first. An ask naming a computer
|
|
104
|
+
// is ignored by every other one; an ask naming none is for anybody.
|
|
100
105
|
if (!ask?.request_id) return;
|
|
106
|
+
const want = String(ask.machine_id || '').trim();
|
|
107
|
+
if (want && want !== machineId()) return undefined;
|
|
101
108
|
if (ask.op === 'list') return answer(ask.request_id, { ok: true, jobs: listJobFiles(root) });
|
|
102
109
|
if (ask.op === 'pause') {
|
|
103
110
|
const { dir } = workspace(ask.job || '', root);
|