fix(extension): bypass 10-item limit of GetAllCascadeTrajectories by utilizing GetDiagnostics

This commit is contained in:
Variet Worker
2026-04-10 16:52:12 +09:00
parent e745744636
commit 300338d5d3
5 changed files with 74 additions and 4 deletions

View File

@@ -126,6 +126,22 @@ export function startHttpBridge(ctx: HttpBridgeContext, sdk: any): Promise<numbe
return;
}
if (req.method === 'POST' && url.pathname === '/test-rpc') {
let rpcBody = '';
req.on('data', (c: string) => rpcBody += c);
req.on('end', async () => {
try {
const params = JSON.parse(rpcBody);
const result = await sdk.ls.rawRPC(params.method, params.args || {});
res.writeHead(200, {'Content-Type': 'application/json'});
res.end(typeof result === 'string' ? result : JSON.stringify(result));
} catch(e: any) {
res.writeHead(500); res.end(e.message);
}
});
return;
}
// GET /ping — health check
if (url.pathname === '/ping') {
res.writeHead(200); res.end('pong');