Skip to content

Make MCP StdioTransport fallible, add tests, and small robustness/docs fixes - #8

Merged
devopsariful merged 1 commit into
mainfrom
codex/fix-typo-in-codebase-6sgmzm
Jul 22, 2026
Merged

Make MCP StdioTransport fallible, add tests, and small robustness/docs fixes#8
devopsariful merged 1 commit into
mainfrom
codex/fix-typo-in-codebase-6sgmzm

Conversation

@devopsariful

Copy link
Copy Markdown
Owner

Motivation

  • Avoid panics when spawning MCP subprocesses and propagate errors so callers can handle failure.
  • Harden Git status and ahead/behind calculations against unexpected git API results.
  • Clean up minor docs/strings and align dependency versions for compatibility.

Description

  • Change StdioTransport::new to return Result<Self> and use anyhow::Context for richer error messages instead of panicking on spawn or I/O capture failures.
  • Update caller in register_server to propagate the fallible StdioTransport::new with ?.
  • Improve git module robustness by using Oid::ZERO_SHA1 and handling potential errors from path() and shorthand() calls more defensively.
  • Add a unit test stdio_transport_spawn_failure_returns_error to ensure invalid MCP commands return an error instead of panicking, and make small spelling/documentation changes in test files and comments.
  • Bump or adjust a few dependency entries in package.json and Cargo.lock to align versions.

Testing

  • Ran cargo test which includes the new unit test stdio_transport_spawn_failure_returns_error, and all unit and integration tests completed successfully.
  • Ran integration tests covering vector store and config (test_vector_store*, test_config) which passed as part of the test run.
  • No automated failures were observed in the modified test suite.

Codex Task

@devopsariful devopsariful self-assigned this Jul 22, 2026
@devopsariful
devopsariful merged commit 4f165b6 into main Jul 22, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant