From dadc87f843318ff04c7cd79ed8d42e7c57110eeb Mon Sep 17 00:00:00 2001 From: Claude Code Date: Sun, 29 Mar 2026 04:57:41 -0700 Subject: [PATCH] =?UTF-8?q?chore(tsup):=20=F0=9F=94=A7=20Update=20build=20?= =?UTF-8?q?configuration=20in=20tsup.config.ts=20for=20model-boss-mcp=20pa?= =?UTF-8?q?ckage?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Lilith Autocommit --- @packages/model-boss-mcp/tsup.config.ts | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/@packages/model-boss-mcp/tsup.config.ts b/@packages/model-boss-mcp/tsup.config.ts index 34e1a97..eea13cf 100644 --- a/@packages/model-boss-mcp/tsup.config.ts +++ b/@packages/model-boss-mcp/tsup.config.ts @@ -35,12 +35,17 @@ export default defineConfig({ }; }); - // ajv-formats requires ajv v8 deep paths (ajv/dist/compile/codegen). - // The workspace has ajv v6 which doesn't have this structure. - // The MCP SDK loads ajv validation lazily and this server never uses it, - // so mark these deep requires as external (they'll never be called at runtime). - build.onResolve({ filter: /^ajv\/dist\// }, () => { - return { path: 'ajv/dist/compile/codegen', external: true }; + // ajv-formats requires ajv v8 (ajv/dist/compile/codegen) which isn't + // installed. The MCP SDK loads ajv validation lazily and this server + // never invokes it. Stub ajv-formats entirely. + build.onResolve({ filter: /^ajv-formats/ }, (args) => { + return { path: args.path, namespace: 'ajv-stub' }; + }); + build.onResolve({ filter: /^ajv\/dist\// }, (args) => { + return { path: args.path, namespace: 'ajv-stub' }; + }); + build.onLoad({ filter: /.*/, namespace: 'ajv-stub' }, () => { + return { contents: 'module.exports = function() {};', loader: 'js' }; }); }, },