mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-24 06:24:18 +02:00
Simplifies the task support story for proxies and mounts: - Mounts get full SEP-1686 task support (unchanged) - Proxies explicitly forbid task execution The cross-session task forwarding for proxies turned out to be complex since each client connection creates a new server lifespan with a new Docket context, and task keys include session_id. Rather than introduce that complexity, proxies now explicitly refuse task-augmented execution. Key changes: - All proxy components (ProxyTool, ProxyPrompt, ProxyResource, ProxyTemplate) now have task_config.mode="forbidden" - Proxy tests verify forbidden behavior (sync execution works, task=True returns error/raises McpError) - Fixed prompt task handler to check hasattr(prompt, "task_config") instead of isinstance(prompt, FunctionPrompt) so it applies to ProxyPrompt too - Added test suites for both proxy and mount task behavior Also includes minor fixes: - Fixed result.meta_ -> result.meta in ProxyTool.run() - Fixed client handling of returned_immediately without taskId - Bumped pydocket>=0.15.2 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| auth | ||
| http | ||
| middleware | ||
| openapi | ||
| proxy | ||
| tasks | ||
| __init__.py | ||
| test_app_state.py | ||
| test_auth_integration.py | ||
| test_context.py | ||
| test_dependencies.py | ||
| test_file_server.py | ||
| test_icons.py | ||
| test_import_server.py | ||
| test_input_validation.py | ||
| test_log_level.py | ||
| test_logging.py | ||
| test_mount.py | ||
| test_run_server.py | ||
| test_server.py | ||
| test_server_docket.py | ||
| test_server_interactions.py | ||
| test_server_lifespan.py | ||
| test_streamable_http_no_redirect.py | ||
| test_tool_annotations.py | ||
| test_tool_exclude_args.py | ||
| test_tool_transformation.py | ||