Skip to content

fix(server): change main to async def#39

Open
iqdoctor wants to merge 2 commits into
xing5:mainfrom
strato-space:main
Open

fix(server): change main to async def#39
iqdoctor wants to merge 2 commits into
xing5:mainfrom
strato-space:main

Conversation

@iqdoctor

@iqdoctor iqdoctor commented Sep 6, 2025

Copy link
Copy Markdown
Contributor

server.main was defined as a sync function returning None, which caused
when executed with
asyncio.run(). Updated to so the entrypoint works properly with asyncio.

Valeriy Pavlovich and others added 2 commits September 6, 2025 23:27
server.main was defined as a sync function returning None, which caused
 when executed with
asyncio.run(). Updated to  so the entrypoint works
properly with asyncio.
Make main async and switch from mcp.run() (anyio.run) to
await mcp.run_stdio_async(), avoiding nested event loop error:
"RuntimeError: Already running asyncio in this thread".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant