mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-23 22:14:18 +02:00
Remove automatic trailing slash modification from server paths
Closes #991 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
d7969b159e
commit
e17397af91
1 changed files with 0 additions and 8 deletions
|
|
@ -158,10 +158,6 @@ def create_sse_app(
|
|||
A Starlette application with RequestContextMiddleware
|
||||
"""
|
||||
|
||||
# Ensure the message_path ends with a trailing slash to avoid automatic redirects
|
||||
if not message_path.endswith("/"):
|
||||
message_path = message_path + "/"
|
||||
|
||||
server_routes: list[BaseRoute] = []
|
||||
server_middleware: list[Middleware] = []
|
||||
|
||||
|
|
@ -309,10 +305,6 @@ def create_streamable_http_app(
|
|||
# Re-raise other RuntimeErrors if they don't match the specific message
|
||||
raise
|
||||
|
||||
# Ensure the streamable_http_path ends with a trailing slash to avoid automatic redirects
|
||||
if not streamable_http_path.endswith("/"):
|
||||
streamable_http_path = streamable_http_path + "/"
|
||||
|
||||
# Add StreamableHTTP routes with or without auth
|
||||
if auth:
|
||||
auth_middleware, auth_routes, required_scopes = (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue