Description
Describe the bug
A clear and concise description of what the bug is.
Description
When attempting to establish SSE connection with MCP Python SDK (v1.6.0), encountering persistent 404 errors on critical endpoints:
mcp = FastMCP("Demo", debug=True, log_level="DEBUG", message_path="/abcd/abcd/messages/")
To Reproduce
Steps to reproduce the behavior:
- Go to '...'
- Click on '....'
- Scroll down to '....'
- See error
[04/14/25 09:45:51] DEBUG Setting up SSE connection sse.py:87
DEBUG session_uri: sse.py:106
/abcd/abcd/messages/?session_id
=b5b93f9d4088442fa3edb1c679a7a922
DEBUG Created new session with ID: sse.py:109
b5b93f9d-4088-442f-a3ed-b1c679a7a922
DEBUG Starting SSE response task sse.py:136
DEBUG Yielding read and write streams sse.py:139
INFO: 100.67.30.95:57894 - "GET /sse HTTP/1.1" 200 OK
DEBUG Starting SSE writer sse.py:116
DEBUG Sent endpoint event: sse.py:119
/abcd/abcd/messages/?session_id
=b5b93f9d4088442fa3edb1c679a7a922
DEBUG chunk: b'event: endpoint\r\ndata: sse.py:156
/abcd/abcd/messages/?session_id
=b5b93f9d4088442fa3edb1c679a7a922\r\n\r\
n'
INFO: 10.183.49.44:60168 - "GET /prometheus HTTP/1.1" 404 Not Found
INFO: 100.67.31.17:49088 - "POST /messages/?session_id=b5b93f9d4088442fa3edb1c679a7a922 HTTP/1.1" 404 Not
Found
DEBUG Got event: http.disconnect. Stop sse.py:177
streaming.
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
Smartphone (please complete the following information):
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]
Additional context
Add any other context about the problem here.