You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sebastianbreguel
e79ec3a266
⚡ Optimize get_flat_dependant: set lookup + copy-on-write lists
Use a set instead of a list for the visited tracker, converting the
membership check from O(n) to O(1). DependencyCacheKey is a hashable
tuple, so the swap is safe.
Defer param list copies until a child actually has data to merge
(copy-on-write). Nodes whose children carry no params skip all five
list allocations entirely, which is the common case for paramless
dependency functions.
Skip the oauth_scopes property call and intermediate list
concatenations when no scopes are present.
Benchmarks (synthetic trees, min of 5×1000 runs, Python 3.11):
| Scenario | Speed | RAM |
|--------------|--------|--------|
| Chain ×100 | −28 % | −12 % |
| Wide 100×3 | −57 % | −29 % |
| Diamond ×100 | −39 % | −31 % |
2 weeks ago
..
.agents/skills/ fastapi
📝 Update Skill, optimize context, trim and refactor into references (#15031)
3 months ago
_compat
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
dependencies
⚡ Optimize get_flat_dependant: set lookup + copy-on-write lists
2 weeks ago
middleware
📝 Use `WSGIMiddleware` from `a2wsgi` instead of deprecated `fastapi.middleware.wsgi.WSGIMiddleware` (#14756)
4 months ago
openapi
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
security
✏️ Fix typo for `client_secret` in OAuth2 form docstrings (#14946)
3 months ago
__init__.py
🔖 Release version 0.136.3
3 weeks ago
__main__.py
♻️ Add support for `pip install "fastapi[standard]"` with standard dependencies and `python -m fastapi` (#11935)
2 years ago
applications.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
background.py
🎨 Update internal types for Python 3.10 (#14898)
4 months ago
cli.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
concurrency.py
♻️ Upgrade internal syntax to Python 3.9+ 🎉 (#14564)
6 months ago
datastructures.py
👷 Add `ty` to precommit (#15091)
3 months ago
encoders.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
exception_handlers.py
⬆️ Upgrade Starlette supported version range to >=0.40.0,<0.49.0 (#14077)
9 months ago
exceptions.py
🎨 Update internal types for Python 3.10 (#14898)
4 months ago
logger.py
🔊 Refactor logging (#781)
7 years ago
param_functions.py
👷 Add `ty` to precommit (#15091)
3 months ago
params.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
py.typed
✨ add py.typed to ship typing information (#209)
7 years ago
requests.py
⬆ Require Pydantic > 1.0 (#1862)
6 years ago
responses.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
routing.py
⬆ Bump ty from 0.0.21 to 0.0.34 (#15443)
1 month ago
sse.py
♻️ Validate Server Sent Event fields to avoid applications from sending broken data (#15588)
3 weeks ago
staticfiles.py
✨ Improve type annotations, add support for mypy --strict, internally and for external packages (#2547)
6 years ago
templating.py
✨ Improve type annotations, add support for mypy --strict, internally and for external packages (#2547)
6 years ago
testclient.py
✨ Improve type annotations, add support for mypy --strict, internally and for external packages (#2547)
6 years ago
types.py
🎨 Update internal types for Python 3.10 (#14898)
4 months ago
utils.py
🎨 Update internal types for Python 3.10 (#14898)
4 months ago
websockets.py
✨ Export `WebSocketState` in `fastapi.websockets` (#4376)
4 years ago