-
Notifications
You must be signed in to change notification settings - Fork 251
Description
Problem Description
The compile MCP tool (agenticworkflows-compile) reports a false-positive compilation failure for mcp-inspector.md with the error exec: "npm": executable file not found in $PATH, while running ./gh-aw compile .github/workflows/mcp-inspector.md directly succeeds without any errors.
Tool
- Tool: compile (agenticworkflows MCP server)
- Workflow:
mcp-inspector.md
Steps to Reproduce
- Verify npm is available:
which npm→/usr/local/bin/npm - Run directly:
./gh-aw compile .github/workflows/mcp-inspector.md→ ✅ Compiles successfully - Run via MCP: Use
agenticworkflows-compilewithworkflows: ["mcp-inspector"]→ ❌ Fails
Expected Behavior
The MCP compile tool should compile mcp-inspector.md successfully, just like the direct CLI invocation.
Actual Behavior
The MCP compile tool returns:
error: runtime package validation failed
Underlying error: exec: "npm": executable file not found in $PATH
Root Cause Analysis
The gh-aw MCP server appears to start with a restricted PATH that does not include /usr/local/bin (or wherever npm is installed). When the MCP server spawns the compilation subprocess, it cannot locate the npm binary, even though it is available in the user's shell environment.
The direct CLI invocation inherits the full shell PATH and can find npm.
Environment
- Repository: github/gh-aw
- Run ID: 22288022720
- Date: 2026-02-22
- npm location:
/usr/local/bin/npm(Node.js v20) - gh-aw version: 0.0.414
Impact
- Severity: High
- Frequency: Always (reproducible 100%)
- Effect:
mcp-inspector.mdalways shows as invalid when compiling via MCP, giving a false-positive failure. This breaks the daily compile check which reportsmcp-inspector.mdas invalid.
Workaround
Run GH_AW_SKIP_NPX_VALIDATION=true gh-aw compile directly. The MCP compile tool does not support this environment variable override.
Suggested Fix
Ensure the MCP server inherits a full PATH when starting, or explicitly add common binary paths (like /usr/local/bin) to the subprocess environment used for compilation.
Generated by Daily CLI Tools Exploratory Tester
- expires on Mar 1, 2026, 11:55 PM UTC