D:\soft\python\python.exe: No module named mysql_mcp_server.__main__; 'mysql_mcp_server' is a package and cannot be directly executed
when i run "python -m mysql_mcp_server" ,error accur
直接mysql_mcp_server, 不行的话添加环境变量
@qinglikong Have you tried configuring and running the mysql_mcp_server via Claude Desktop?
I'm facing the exact same issue, I'm trying to run it from docker, just edited dockerfile with env vars, build image, and then run, but it dies immediately
@qinglikong Have you tried configuring and running the mysql_mcp_server via Claude Desktop?
fine , running the mysql_mcp_server via Claude Desktop is OK ,thanks
mysql_mcp_server does not support python -m because it does not comply with the -m code specification. You can uvx mysql_mcp_server or uv --directory {path}\src run mysql_mcp_server
After careful consideration, I've decided not to add a main.py file at this time.
While I appreciate the flexibility this would add for running the server via python -m mysql_mcp_server, the mysql_mcp_server is specifically designed to be integrated with AI applications rather than run as a standalone tool. Using uv as the execution method is the recommended approach for MCP servers in our ecosystem, as it provides better dependency management and consistent behavior with how the server is intended to be used in production.
Adding a main.py entry point could give users the impression that the server is meant to be run standalone, which might lead to confusion about its intended use.
I've updated the README to clarify that this server should be run via uv and to use the MCP Inspector for debugging purposes. Thank you again for your contribution and understanding.