anthropics / anthropics/skills
mcp-builder: requirements.txt allows mcp>=2, where connections.py fails at import (streamablehttp_client renamed)
- Dominant language
- Python
- Stars
- 176k
- Forks
- 20.8k
- Avg merge
- 7h 21m
- Merged PRs (30d)
- 5
Description
## Summary
`skills/mcp-builder/scripts/requirements.txt` pins `mcp>=1.1.0` with no upper bound. The MCP Python SDK is now at 2.x, where `streamablehttp_client` has been **renamed** to `streamable_http_client`. `connections.py` imports the old name at module scope, so a fresh install of the documented requirements fails at import — before any MCP server, evaluation file, or API key is involved.
This is the first thing anyone following the Phase-4 instructions hits today.
## Repro
```bash
python -m venv .venv
.venv/bin/pip install -r skills/mcp-builder/scripts/requirements.txt # resolves mcp 2.x
.venv/bin/python skills/mcp-builder/scripts/evaluation.py -t stdio -c node -a server.js eval.xml
```
```
Traceback (most recent call last):
File ".../scripts/evaluation.py", line 19, in
from connections import create_connection
File ".../scripts/connections.py", line 10, in
from mcp.client.streamable_http import streamablehttp_client
ImportError: cannot import name 'streamablehttp_client' from 'mcp.client.streamable_http'
```
Confirmed on `mcp` 2.1.1:
```python
>>> import mcp.client.streamable_http as s
>>> [n for n in dir(s) if 'client' in n.lower()]
['ClientMessageMetadata', 'create_mcp_http_client', 'streamable_http_client']
```
## Fix
Either cap the requirement:
```
mcp>=1.1.0,<2
```
or support both names in `connections.py`:
```python
try:
from mcp.client.streamable_http import streamable_http_client
except ImportError: # mcp < 2
from mcp.client.streamable_http import streamablehttp_client as streamable_http_client
```
The second is preferable — pinning `<2` in a shared environment holds back anything else on the machine using the SDK, which pushes users toward a throwaway venv for what should be a two-line install.
## Environment
- Windows 11, Python 3.13.14
- `mcp` 2.1.1 (fails), 1.29.1 (works)
- `anthropic` 1.0.0
## Context
Found while running the Phase-4 evaluation against a stdio MCP server exposing 66 tools. It was one of several independent failures between "follow the skill's instructions" and "get a score"; the others are #1390, #1386, and the report-write bug filed alongside this one. Happy to send a PR for whichever fix you prefer.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.