fastmcp/loq.toml
Jeremiah Lowin c35fa5b9e4
[3.x] Require a startup-URL session for the fastmcp dev apps preview (#5418)
Backports `security/dev-apps-preview-server` from main. The `fastmcp dev apps` UI runs as a session started from the printed startup URL, checks Host and origin, opens only launches the picker created, sandboxes tool UI resources in an opaque origin, escapes picker errors, and starts the MCP server with `FASTMCP_HTTP_HOST_ORIGIN_PROTECTION=auto` unless that variable is set. Behavior and compatibility effects match main.

Co-authored-by: Bill Easton <williamseaston@gmail.com>
Co-authored-by: Claude <noreply@anthropic.com>
2026-10-04 10:51:29 -04:00

75 lines
1.5 KiB
TOML

# loq configuration - file size enforcement
# Run `loq baseline` to update when files exceed limits
default_max_lines = 1000
respect_gitignore = true
exclude = ["**/uv.lock", ".git/**", ".claude/**", "docs/**"]
[[rules]]
path = "tests/**"
max_lines = 1000
[[rules]]
path = "fastmcp_slim/fastmcp/server/context.py"
max_lines = 1404
[[rules]]
path = "fastmcp_slim/fastmcp/server/server.py"
max_lines = 2410
[[rules]]
path = "fastmcp_slim/fastmcp/server/auth/oauth_proxy/proxy.py"
max_lines = 2098
[[rules]]
path = "fastmcp_slim/fastmcp/cli/apps_dev.py"
max_lines = 1934
[[rules]]
path = "fastmcp_slim/fastmcp/cli/cli.py"
max_lines = 1116
[[rules]]
path = "fastmcp_slim/fastmcp/server/dependencies.py"
max_lines = 1686
[[rules]]
path = "fastmcp_slim/fastmcp/server/providers/proxy.py"
max_lines = 1096
[[rules]]
path = "fastmcp_slim/fastmcp/tools/tool_transform.py"
max_lines = 1004
[[rules]]
path = "tests/resources/test_resource_template.py"
max_lines = 1016
[[rules]]
path = "tests/server/providers/openapi/test_openapi_features.py"
max_lines = 1029
[[rules]]
path = "tests/server/tasks/test_task_mount.py"
max_lines = 1088
[[rules]]
path = "tests/server/test_dependencies.py"
max_lines = 1194
[[rules]]
path = "tests/test_mcp_config.py"
max_lines = 1185
[[rules]]
path = "tests/utilities/openapi/test_director.py"
max_lines = 1154
[[rules]]
path = "fastmcp_slim/fastmcp/utilities/json_schema_type.py"
max_lines = 1019
[[rules]]
path = "tests/cli/test_run.py"
max_lines = 1291