Skip to content

mcp: on macOS and Linux the server warns that every tool will fail, though the tools work #1357

Description

@swapnilpaliwal-sd

On macOS and Linux, axiomcode mcp always prints this warning to stderr:

axiomcode mcp: AXIOMCODE_BASH is set to bash, which does not exist.
  The server starts, but every tool will say it cannot run the CLI.

The warning is false: tools/call returns correct answers. An MCP client that shows server stderr tells the user the tools are broken when they work.

Cause. On a non-Windows platform findBash() returns the bare name bash, and bin/axiomcode.js exports it as AXIOMCODE_BASH=bash. axiomcode mcp then goes through mcp/launch.js, which calls findBash() again. It sees the override and checks fs.existsSync("bash"), which is resolved against the working directory, so the check fails. server.py still inherits AXIOMCODE_BASH=bash and runs normally.

Fix. Test for existence only when the override is a path, or have bin/axiomcode.js export AXIOMCODE_BASH only when it holds an absolute path.

Found by an end-to-end run of 0.1.1 on macOS and Linux. Windows is not affected, because there the value is an absolute path.

Activity

  1. added
    bugSomething isn't working
    pluginthe axiomcode plugin: skill + MCP layer
    mcpthe MCP layer of the plugin
    on Sep 26, 2026
  2. swapnilpaliwal-sd commented on Oct 8, 2026

    @swapnilpaliwal-sd
    ContributorAuthor

    Still reproduces on apps/integration-0.1.9 (2026-10-08), and two external evaluations reported it independently on 0.1.8.

    Reproduction (macOS): start axiomcode mcp, send initialize: the server answers, and stderr says

    axiomcode mcp: AXIOMCODE_BASH is set to bash, which does not exist.
      The server starts, but every tool will say it cannot run the CLI.
    

    Cause, confirmed: bin/axiomcode.js exports AXIOMCODE_BASH=bash (the bare name findBash() returns on POSIX); mcp/launch.js calls findBash() again, which checks the override with fs.existsSync, a file-path test, so a program name always "does not exist".

    Fix: a bare name is resolved on PATH; a path is checked as written; either one missing remains an error (exit 127). Regression test in tests/mcp.py fails on the current code with the reported message and passes with the fix. PR to follow.

  3. swapnilpaliwal-sd commented on Oct 8, 2026

    @swapnilpaliwal-sd
    ContributorAuthor

    Fixed by #1867, merged into apps/integration-0.1.9 (e0e8450); ships with 0.1.9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugSomething isn't workingmcpthe MCP layer of the pluginpluginthe axiomcode plugin: skill + MCP layer

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions