@@ -6801,12 +6801,12 @@ var require_dist = __commonJS({
68016801 throw new Error(`Unknown format "${name}"`);
68026802 return f;
68036803 };
6804- function addFormats(ajv, list, fs9 , exportName) {
6804+ function addFormats(ajv, list, fs8 , exportName) {
68056805 var _a;
68066806 var _b;
68076807 (_a = (_b = ajv.opts.code).formats) !== null && _a !== void 0 ? _a : _b.formats = (0, codegen_1._)`require("ajv-formats/dist/formats").${exportName}`;
68086808 for (const f of list)
6809- ajv.addFormat(f, fs9 [f]);
6809+ ajv.addFormat(f, fs8 [f]);
68106810 }
68116811 module.exports = exports = formatsPlugin;
68126812 Object.defineProperty(exports, "__esModule", { value: true });
@@ -18782,7 +18782,6 @@ var StdioClientTransport = class {
1878218782// server.ts
1878318783import path from "path";
1878418784import { fileURLToPath } from "url";
18785- import fs8 from "fs";
1878618785
1878718786// tools/delete_cell.ts
1878818787import * as fs from "fs/promises";
@@ -19266,52 +19265,36 @@ async function startStandaloneServer() {
1926619265}
1926719266async function run() {
1926819267 const ideName = process.env.DATA_CLOUD_CURR_IDE_NAME;
19269- const logPath = "/tmp/mcp_debug.log";
19270- const log = (msg) => {
19271- fs8.appendFileSync(logPath, `[${(/* @__PURE__ */ new Date()).toISOString()}] ${msg}
19272- `);
19273- console.error(msg);
19274- };
19275- log(`Server started. DATA_CLOUD_CURR_IDE_NAME=${ideName}`);
1927619268 if (ideName) {
19277- log(`IDE environment detected via env var (${ideName}).`);
1927819269 const proxyCmd = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../bin/mcp_proxy_bundle.cjs");
1927919270 try {
19280- log(`Spawning Notebooks proxy...`);
1928119271 const notebookTransport = new StdioClientTransport({
1928219272 command: process.execPath,
1928319273 args: [proxyCmd, `notebooks-${ideName.toLowerCase()}`],
1928419274 env: process.env
1928519275 });
1928619276 notebookClient = new Client({ name: "notebook-client", version: "0.1.0" }, { capabilities: {} });
1928719277 await notebookClient.connect(notebookTransport);
19288- log("Connected to Notebooks proxy");
1928919278 } catch (e) {
19290- log(`Failed to connect to Notebooks proxy: ${e}`);
1929119279 notebookClient = null;
1929219280 }
1929319281 try {
19294- log(`Spawning Visualization proxy...`);
1929519282 const vizTransport = new StdioClientTransport({
1929619283 command: process.execPath,
1929719284 args: [proxyCmd, `visualization-${ideName.toLowerCase()}`],
1929819285 env: process.env
1929919286 });
1930019287 vizClient = new Client({ name: "viz-client", version: "0.1.0" }, { capabilities: {} });
1930119288 await vizClient.connect(vizTransport);
19302- log("Connected to Visualization proxy");
1930319289 } catch (e) {
19304- log(`Failed to connect to Visualization proxy: ${e}`);
1930519290 vizClient = null;
1930619291 }
1930719292 if (!notebookClient && !vizClient) {
19308- log("Both proxies failed. Falling back to standalone server");
1930919293 await startStandaloneServer();
1931019294 return;
1931119295 }
1931219296 const transport = new StdioServerTransport();
1931319297 await server.connect(transport);
19314- log("Master aggregator server running on stdio");
1931519298 return;
1931619299 }
1931719300 await startStandaloneServer();
0 commit comments