Skip to content

Commit 99df817

Browse files
committed
fix(runtime): build blob transfer payload explicitly
1 parent bbd86b7 commit 99df817

1 file changed

Lines changed: 15 additions & 11 deletions

File tree

packages/runtime/src/python-bridge-base.ts

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -637,23 +637,27 @@ export abstract class PythonBridgeBase
637637

638638
log.debug("Python bridge execute dispatched", { nodeType, requestId });
639639

640+
const executeData: Record<string, unknown> = {
641+
node_type: nodeType,
642+
fields,
643+
secrets,
644+
blobs,
645+
...this._identityPayload(identity)
646+
};
647+
if (
648+
this._workerStatus?.protocol_version != null &&
649+
this._workerStatus.protocol_version >= 5
650+
) {
651+
executeData["blob_transfer"] = "chunked-v1";
652+
}
653+
640654
const executePromise = new Promise<ExecuteResult>((resolve, reject) => {
641655
this._pending.set(requestId, { resolve, reject, onProgress });
642656
try {
643657
this._send({
644658
type: "execute",
645659
request_id: requestId,
646-
data: {
647-
node_type: nodeType,
648-
fields,
649-
secrets,
650-
blobs,
651-
...(this._workerStatus?.protocol_version != null &&
652-
this._workerStatus.protocol_version >= 5
653-
? { blob_transfer: "chunked-v1" }
654-
: {}),
655-
...this._identityPayload(identity)
656-
}
660+
data: executeData
657661
});
658662
} catch (err) {
659663
this._pending.delete(requestId);

0 commit comments

Comments
 (0)