接续L4-TOOL-DB浏览器Provider协议
结论:浏览器 Worker 已支持可插拔 Python runtime provider 的 line I/O,缺真实 Python/WASM runtime 时仍保持阻塞不解锁。
This commit is contained in:
@@ -96,7 +96,14 @@ export function createLinuxCncToolDbBrowserWorkerAdapter({
|
||||
return result.line;
|
||||
},
|
||||
|
||||
close() {
|
||||
async close() {
|
||||
if (worker) {
|
||||
try {
|
||||
await request("close");
|
||||
} catch {
|
||||
// The worker may be blocked or already gone; termination below is authoritative.
|
||||
}
|
||||
}
|
||||
rejectPending(new Error("Tool DB browser worker closed."));
|
||||
worker?.terminate();
|
||||
worker = null;
|
||||
|
||||
Reference in New Issue
Block a user