traceloop / traceloop/openllmetry
๐ Bug Report: Unsupported mcp==2.x module 'streamablehttp_client'
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 7.4k
- Forks
- 1.1k
- Avg merge
- 8d 14h
- Merged PRs (30d)
- 2
Description
Which component is this bug for?
Traceloop SDK
๐ Description
register_post_import_hook(
lambda _: wrap_function_wrapper(
"mcp.client.streamable_http",
"streamablehttp_client",
self._transport_wrapper(tracer),
),
"mcp.client.streamable_http",
)
The mcp.client.streamable_http module is removed from mcp-sdk 2.x
With mcp==2.0.0 version, the traceloop fail to bootstrap with error
Error initializing MCP instrumentor: module 'mcp.client.streamable_http' has no attribute 'streamablehttp_client'
๐ Reproduction steps
mcp>=2.0.0
Traceloop==0.62.3
opentelemetry-api==1.44.0
opentelemetry-sdk==1.44.0
Start mcp server
๐ Expected behavior
Start stable with instrumentation enabled
๐ Actual Behavior with Screenshots
Error initializing MCP instrumentor: module 'mcp.client.streamable_http' has no attribute 'streamablehttp_client'
๐ค Python Version
3.12
๐ Provide any additional context for the Bug.
No response
๐ Have you spent some time to check if this bug has been raised before?
- I checked and didn't find similar issue
Are you willing to submit PR?
Yes I am willing to submit a PR!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up โ it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with packages/opentelemetry-instrumentation-mcp/opentelemetry/instrumentation/mcp/instrumentation.py and inspect how the MCP client hook targets streamablehttp_client. Compare that entry point with mcp==2.0.0 using the reported dependency versions. Done means the Traceloop SDK bootstraps with instrumentation enabled and starts without the reported attribute error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- observability-sre
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100