Commit Graph

52 Commits

Author SHA1 Message Date
marcus 81ff649ab7 Fix stdio startup for Claude Desktop compatibility
- Replace asyncio.run() with anyio.run() in serve command: FastMCP uses
  anyio.create_task_group() internally, and anyio.run() ensures the correct
  backend context. asyncio.run() can misbehave on Windows (ProactorEventLoop).
- Add SERVER STARTING / MCP server ready messages to stderr for diagnostics.
- Replace sys.exit(1) with early return + stderr write inside anyio context;
  sys.exit inside anyio.run() is less predictable than a clean return.
- Eagerly import all modules at serve startup so ImportErrors surface on
  stderr immediately instead of silently killing the process.
- Add __main__.py to allow python -m mcp_synology_container invocation.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-13 15:02:29 +02:00
marcus a0c1b6ed93 Initial implementation 2026-04-13 14:22:37 +02:00