fastapi/fastapi
How to contribute
The official process is the contributing guide on the docs site. CONTRIBUTING.md in the repo root is a one-line pointer to that page. This wiki section captures the parts a developer cares about while working in the codebase.
Pickup workflow
- Fork on GitHub, branch off
master. - Run
uv sync --all-extras --group dev(or PDM equivalent) to install everything tests need. - Make changes. Touch
fastapi/, the corresponding tests, and any tutorial example underdocs_src/if the change is observable in user examples. - Run
bash scripts/lint.shandbash scripts/test.shlocally. - Open the PR. CI runs the same lint + tests, plus build-redistribute, docs build, and the smokeshow coverage uploader.
Definition of done
- Tests cover the change. The pyproject coverage source includes
fastapi,tests, anddocs_srcβ touchingdocs_src/typically requires a matching test undertests/test_tutorial/. bash scripts/lint.shpasses (mypy + ty + ruff).- For changes to public API, a release-notes entry is not added by hand β
github-actions[bot]regeneratesπ Update release notescommits via.github/workflows/latest-changes.yml. - For changes to translated content, the
notify-translations.ymlworkflow opens issues in language-specific tracking threads.
What to read before changing each area
| If you're touching⦠| Read first |
|---|---|
fastapi/applications.py |
Application core |
fastapi/routing.py |
Routing |
fastapi/dependencies/ |
Dependency injection |
fastapi/openapi/ |
OpenAPI generation |
fastapi/security/ |
Security |
fastapi/_compat/ |
Pydantic compatibility |
tests/ |
Testing |
docs_src/ |
Tooling β the docs build and translation pipeline |
Sub-pages
Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.
Previous
Fun facts
Next
Development workflow