Skip to content

add mcp pkg #6699

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -317,10 +317,12 @@ async def _send_message(self, run_id: int, message: dict) -> None:
async def _handle_stream_error(self, run_id: int, error: Exception) -> None:
"""Handle stream errors with proper run updates"""
if run_id not in self._closed_connections:
err_detail = str(error)
err_brief = err_detail.split("Traceback", 1)[0].strip() if "Traceback" in err_detail else err_detail
error_result = TeamResult(
task_result=TaskResult(
messages=[TextMessage(source="system", content=str(error))],
stop_reason="An error occurred while processing this run",
messages=[TextMessage(source="system", content=err_detail)],
stop_reason=f"An error occurred while processing this run: {err_brief}",
),
usage="",
duration=0,
Expand Down
1 change: 1 addition & 0 deletions python/packages/autogen-studio/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ dependencies = [
"autogen-agentchat>=0.4.9.2,<0.7",
"autogen-ext[magentic-one, openai, azure]>=0.4.2,<0.7",
"anthropic",
"mcp>=1.9.2",
]
optional-dependencies = {web = ["fastapi", "uvicorn"], database = ["psycopg"]}

Expand Down