# Method Not Allowed: 405

- **ID:** `python/starlette-request-method-error`
- **Domain:** python
- **Category:** network_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

请求使用不支持的 HTTP 方法访问路由。

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.x | active | — | — |

## Workarounds

1. **** (95% success)
   ```
   使用 @app.route(..., methods=["GET"]) 指定允许的方法
   ```
2. **** (90% success)
   ```
   添加自定义 405 处理
   ```
3. **** (85% success)
   ```
   使用 Router 并正确配置方法
   ```

## Dead Ends

- **** — 不正确的语义。 (60% fail)
- **** — 可能暴露不必要的操作。 (70% fail)
- **** — 无法控制所有客户端。 (50% fail)
