@bian-womp/spark-workbench 0.2.76 → 0.2.77
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/lib/cjs/index.cjs +10 -32
- package/lib/cjs/index.cjs.map +1 -1
- package/lib/cjs/src/runtime/IGraphRunner.d.ts +1 -1
- package/lib/cjs/src/runtime/IGraphRunner.d.ts.map +1 -1
- package/lib/cjs/src/runtime/RemoteGraphRunner.d.ts +2 -2
- package/lib/cjs/src/runtime/RemoteGraphRunner.d.ts.map +1 -1
- package/lib/esm/index.js +10 -32
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/src/runtime/IGraphRunner.d.ts +1 -1
- package/lib/esm/src/runtime/IGraphRunner.d.ts.map +1 -1
- package/lib/esm/src/runtime/RemoteGraphRunner.d.ts +2 -2
- package/lib/esm/src/runtime/RemoteGraphRunner.d.ts.map +1 -1
- package/package.json +4 -4
package/lib/cjs/index.cjs
CHANGED
|
@@ -1362,7 +1362,7 @@ class RemoteGraphRunner extends AbstractGraphRunner {
|
|
|
1362
1362
|
this.emit("status", { running: true, engine: this.runningKind });
|
|
1363
1363
|
// Re-apply staged inputs using client.setInputs for consistency
|
|
1364
1364
|
for (const [nodeId, map] of Object.entries(this.stagedInputs)) {
|
|
1365
|
-
await
|
|
1365
|
+
await eng.setInputs(nodeId, map).catch(() => {
|
|
1366
1366
|
// Ignore errors during launch - inputs will be set when user calls setInputs
|
|
1367
1367
|
});
|
|
1368
1368
|
}
|
|
@@ -1408,7 +1408,7 @@ class RemoteGraphRunner extends AbstractGraphRunner {
|
|
|
1408
1408
|
this.emit("status", { running: true, engine: this.runningKind });
|
|
1409
1409
|
// Re-apply staged inputs using client.setInputs for consistency
|
|
1410
1410
|
for (const [nodeId, map] of Object.entries(currentInputs)) {
|
|
1411
|
-
await
|
|
1411
|
+
await eng.setInputs(nodeId, map).catch(() => {
|
|
1412
1412
|
// Ignore errors during engine switch - inputs will be set when user calls setInputs
|
|
1413
1413
|
});
|
|
1414
1414
|
}
|
|
@@ -1437,10 +1437,9 @@ class RemoteGraphRunner extends AbstractGraphRunner {
|
|
|
1437
1437
|
this.stagedInputs[nodeId][handle] = value;
|
|
1438
1438
|
}
|
|
1439
1439
|
}
|
|
1440
|
-
// Use transport.request instead of transport.send for consistency
|
|
1441
|
-
const client = await this.ensureClient();
|
|
1442
1440
|
try {
|
|
1443
|
-
await
|
|
1441
|
+
const client = await this.ensureClient();
|
|
1442
|
+
await client.getEngine()?.setInputs(nodeId, inputs, options);
|
|
1444
1443
|
}
|
|
1445
1444
|
catch (err) {
|
|
1446
1445
|
// Emit synthetic events if connection fails
|
|
@@ -1452,36 +1451,15 @@ class RemoteGraphRunner extends AbstractGraphRunner {
|
|
|
1452
1451
|
}
|
|
1453
1452
|
async copyOutputs(fromNodeId, toNodeId, options) {
|
|
1454
1453
|
const client = await this.ensureClient();
|
|
1455
|
-
await client.copyOutputs(fromNodeId, toNodeId, options);
|
|
1454
|
+
await client.getEngine()?.copyOutputs(fromNodeId, toNodeId, options);
|
|
1456
1455
|
}
|
|
1457
|
-
async
|
|
1456
|
+
async triggerExternal(nodeId, event, options) {
|
|
1458
1457
|
const client = await this.ensureClient();
|
|
1459
|
-
|
|
1460
|
-
if (transport && transport.send) {
|
|
1461
|
-
transport.send({
|
|
1462
|
-
seq: Date.now(),
|
|
1463
|
-
ts: Date.now(),
|
|
1464
|
-
message: {
|
|
1465
|
-
type: "SetViewport",
|
|
1466
|
-
payload: { viewport },
|
|
1467
|
-
},
|
|
1468
|
-
});
|
|
1469
|
-
}
|
|
1458
|
+
await client.getEngine()?.triggerExternal(nodeId, event, options);
|
|
1470
1459
|
}
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
this.engine.triggerExternal(nodeId, event, options);
|
|
1475
|
-
}
|
|
1476
|
-
else {
|
|
1477
|
-
this.ensureClient()
|
|
1478
|
-
.then((client) => {
|
|
1479
|
-
client.getEngine().triggerExternal(nodeId, event, options);
|
|
1480
|
-
})
|
|
1481
|
-
.catch(() => {
|
|
1482
|
-
// Silently fail if connection not available
|
|
1483
|
-
});
|
|
1484
|
-
}
|
|
1460
|
+
async setViewport(viewport) {
|
|
1461
|
+
const client = await this.ensureClient();
|
|
1462
|
+
await client.setViewport(viewport);
|
|
1485
1463
|
}
|
|
1486
1464
|
async coerce(from, to, value) {
|
|
1487
1465
|
const client = await this.ensureClient();
|