@justanothermldude/mcp-exec 1.7.5 → 1.7.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -414,7 +414,8 @@ function generateMethodDefinition(tool, serverName, bridgePort) {
414
414
  // Use escapeForTemplateLiteral to prevent backtick/`${}` injection in error messages
415
415
  const tlSafe = (s) => escapeForTemplateLiteral(s);
416
416
  lines.push(` if (!response.ok) {`);
417
- lines.push(` throw new Error(\`[${tlSafe(safeServerName)}.${tlSafe(safeToolName)}] HTTP \${response.status}: \${response.statusText}\`);`);
417
+ lines.push(` const errBody = await response.text().catch(() => '');`);
418
+ lines.push(` throw new Error(\`[${tlSafe(safeServerName)}.${tlSafe(safeToolName)}] HTTP \${response.status}: \${response.statusText}\${errBody ? ' — ' + errBody.slice(0, 500) : ''}\`);`);
418
419
  lines.push(` }`);
419
420
  lines.push(` const data = await response.json() as { success: boolean; content?: unknown; error?: string; isError?: boolean };`);
420
421
  lines.push(` if (!data.success) {`);
package/dist/index.js CHANGED
@@ -677,7 +677,8 @@ function generateMethodDefinition(tool, serverName, bridgePort) {
677
677
  lines.push(` });`);
678
678
  const tlSafe = /* @__PURE__ */ __name((s) => escapeForTemplateLiteral(s), "tlSafe");
679
679
  lines.push(` if (!response.ok) {`);
680
- lines.push(` throw new Error(\`[${tlSafe(safeServerName)}.${tlSafe(safeToolName)}] HTTP \${response.status}: \${response.statusText}\`);`);
680
+ lines.push(` const errBody = await response.text().catch(() => '');`);
681
+ lines.push(` throw new Error(\`[${tlSafe(safeServerName)}.${tlSafe(safeToolName)}] HTTP \${response.status}: \${response.statusText}\${errBody ? ' \u2014 ' + errBody.slice(0, 500) : ''}\`);`);
681
682
  lines.push(` }`);
682
683
  lines.push(` const data = await response.json() as { success: boolean; content?: unknown; error?: string; isError?: boolean };`);
683
684
  lines.push(` if (!data.success) {`);
@@ -2001,7 +2002,7 @@ __name(createMcpExecServer, "createMcpExecServer");
2001
2002
  // dist/index.js
2002
2003
  import { ServerPool, createConnection, getServerConfig as getServerConfig2, loadServerManifest as loadServerManifest2, cleanupOrphanedProcesses } from "@justanothermldude/meta-mcp-core";
2003
2004
  var APP_NAME = "mcp-exec";
2004
- var VERSION2 = "1.7.4";
2005
+ var VERSION2 = "1.7.5";
2005
2006
  var defaultExecutor = null;
2006
2007
  function getDefaultExecutor() {
2007
2008
  if (!defaultExecutor) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@justanothermldude/mcp-exec",
3
- "version": "1.7.5",
3
+ "version": "1.7.6",
4
4
  "description": "MCP execution utilities for sandboxed code execution with OS-level isolation",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",