Skip to content

feat: introduce framework-agnostic McpHttpError for HTTP layer decoupling#143

Merged
hashemix merged 1 commit into
mainfrom
chore/lose-couling-errors
May 23, 2026
Merged

feat: introduce framework-agnostic McpHttpError for HTTP layer decoupling#143
hashemix merged 1 commit into
mainfrom
chore/lose-couling-errors

Conversation

@hashemix
Copy link
Copy Markdown
Member

📌 Summary

Introduces McpHttpError and McpHttpResult , a framework-agnostic error
abstraction living in mcp_http/. This is step 1 of a larger effort to
decouple Axum from the core SDK crate .

✨ Changes Made

  • New McpHttpError enum with 5 variants mirroring the transport-agnostic subset
    of TransportServerError: SessionIdMissing, SessionIdInvalid,
    StreamIoError, HttpError, TransportError

  • McpHttpResult<T> type alias

  • implemented From<McpHttpError> for TransportServerError

  • implemented From<TransportServerError> for McpHttpError , common variants map
    directly; framework-specific variants (ServerStartError, SslCertError,
    etc.) map to HttpError (lossy but covers the common path)

  • new tests covering conversion paths

@hashemix hashemix merged commit 2e3c4ca into main May 23, 2026
5 of 6 checks passed
@hashemix hashemix mentioned this pull request May 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant