fix rpc no-route errors, fix fileopen in preview (#313)

This commit is contained in:
Mike Sawka
2024-09-03 21:08:51 -07:00
committed by GitHub
parent 558fda1253
commit a7746bc5cc
7 changed files with 63 additions and 9 deletions
+8
View File
@@ -103,6 +103,14 @@ function handleIncomingRpcMessage(msg: RpcMessage, eventHandlerFn: (event: WaveE
}
return;
}
if (msg.command == "message") {
if (msg.data?.oref != null) {
console.log("rpc:message", msg.data?.oref, msg.data?.message);
} else {
console.log("rpc:message", msg.data?.message);
}
return;
}
console.log("rpc command not supported", msg);
return;
+5
View File
@@ -107,6 +107,11 @@ class WshServerType {
return WOS.wshServerRpcHelper_call("remotefileinfo", data, opts);
}
// command "remotefilejoin" [call]
RemoteFileJoinCommand(data: string[], opts?: RpcOpts): Promise<FileInfo> {
return WOS.wshServerRpcHelper_call("remotefilejoin", data, opts);
}
// command "remotestreamcpudata" [responsestream]
RemoteStreamCpuDataCommand(opts?: RpcOpts): AsyncGenerator<TimeSeriesData, void, boolean> {
return WOS.wshServerRpcHelper_responsestream("remotestreamcpudata", null, opts);