Skip to content

bare mode: MCP connections established despite --bare skip guarantee #3298

@bug-ops

Description

@bug-ops

Description

--bare is documented as: "skip skill loading, memory init, MCP connections, scheduler startup, and filesystem watchers." However, live testing confirms MCP connections are established unconditionally in bare mode — bypassing the documented skip guarantee.

Additionally, the HTTP gateway server spawns in bare mode with no exec_mode.bare guard at the spawn site.

Reproduction Steps

  1. Run: echo 'hello' | zeph --config .local/config/testing.toml --bare 2>&1 | grep -E 'MCP|connect|gateway'
  2. Observe MCP servers (fs-test, todoist) connecting and gateway spawning on 127.0.0.1:8090

Expected Behavior

In --bare mode: no MCP connections established, no gateway spawned. Bare mode should be a minimal LLM round-trip without external service dependencies.

Actual Behavior

INFO mcp.connect{server_id=fs-test}: Service initialized as client ...
INFO mcp.connect_all: connected to MCP server server_id="fs-test" tools=1
INFO mcp.connect_url{server_id=todoist}: Service initialized as client ...
INFO zeph::gateway_spawn: Gateway server spawned on 127.0.0.1:8090
WARN zeph_gateway::server: gateway running without bearer auth

Graph-memory also activates (memory.graph_extract runs) despite semantic memory being replaced by in-memory SQLite.

Root Cause (Code Pointers)

  • src/runner.rs:687-696 — skill registry and watchers guarded by exec_mode.bare
  • src/runner.rs:793-796 — semantic memory replaced with bare SQLite
  • MCP manager call site: no exec_mode.bare guard — MCP always connects
  • src/runner.rs:2362-2410 — gateway spawn site: no exec_mode.bare guard
  • src/runner.rs:1988agent.with_graph_config() called unconditionally

Environment

  • Version: v0.19.3
  • Config: .local/config/testing.toml
  • Features: full
  • Command: echo 'hello' | zeph --config .local/config/testing.toml --bare

Metadata

Metadata

Assignees

Labels

P2High value, medium complexitybugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions