Skip to content

ImportError: cannot import name 'MCPServerStdio' from 'agents.mcp' #691

Open
@kushagra2jindal

Description

@kushagra2jindal

Describe the bug

While using the sample agent code - https://github.com/openai/openai-agents-python/blob/main/examples/mcp/filesystem_example/main.py it gives the following error

ImportError: cannot import name 'MCPServerStdio' from 'agents.mcp'

Debug information

  • Agents SDK version: 0.0.14
  • Python version 3.9.6

Repro steps

import asyncio
import os
import shutil

from agents import Agent, Runner, gen_trace_id, trace
from agents.mcp import MCPServerStdio

The above import itself give the error

Expected behaviour

It should execute the script above

Note

If I change to python version - 3.11.5 the import works as per the expectations

Metadata

Metadata

Assignees

No one assigned

    Labels

    wontfixThis will not be worked on

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions