modelcontextprotocol / modelcontextprotocol/python-sdk

MCP client not able to initiate StdioServerParameters while running in Jupyter Notebook

Open
#1,103 6 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug needs repro
Dominant language
Python
Stars
24.3k
Forks
4k
Avg merge
1d 1h
Merged PRs (30d)
31

Description

while initiating StdioServerParameters in jupyter notebook there is an Exception from subprocess.Popen.
Exception is : UnsupportedOperation fileno

Same code works in idle and with quart server.

OS : windows 11
Python version: 3.11

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing StdioServerParameters initialization in a Windows 11 Jupyter Notebook with Python 3.11, then compare the subprocess.Popen path with the working IDLE and Quart cases. Investigate the fileno failure and identify the SDK entry point involved; done means the notebook case works without regressing the other environments and has regression coverage.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook, python
Domain
developer-experience
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.