Fix navi-3d MCP tool coroutine serialization error
All three tool handlers (compile_scad, render_stl, lint_scad) were
calling async core functions without await from synchronous def bodies.
This caused FastMCP to receive a coroutine object instead of a dict,
which then failed JSON serialization with:
  Object of type coroutine is not JSON serializable

Fix: convert tool handlers to async def and await the underlying
compile_scad / render_stl / lint_scad calls before passing to _json().

Tested via stdio_client — lint_scad now returns clean JSON result.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 6c4a569 commit a6f8f9b5e8e017e9452c445668b49994d146f8b4
@Eugene Sukhodolskiy Eugene Sukhodolskiy authored on 13 May
Showing 1 changed file
View
mcp-servers/navi-3d/app/mcp_server.py