FastAPI framework, high performance, easy to learn, fast to code, ready for production
This report presents the forensic synthetic code analysis of fastapi/fastapi, a Python project with 100,450 GitHub stars. SynthScan v2.0 examined 369,351 lines of code across 2770 source files, recording 1836 pattern matches distributed across 16 syntactic categories. The overall adjusted score of 6.2 places this repository in the Low AI signal band.
The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).
This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 1836 distinct pattern matches across 16 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | tests/test_datastructures.py | 16 | def test_default_placeholder_equals(): | CODE |
| LOW⚡ | tests/test_datastructures.py | 23 | def test_default_placeholder_bool(): | CODE |
| LOW⚡ | tests/test_datastructures.py | 30 | def test_upload_file_is_closed(tmp_path: Path): | CODE |
| LOW | tests/test_starlette_exception.py | 23 | async def no_body_status_code_exception(): | CODE |
| LOW | tests/test_starlette_exception.py | 28 | async def no_body_status_code_with_detail_exception(): | CODE |
| LOW⚡ | tests/test_starlette_exception.py | 61 | def test_get_starlette_item_not_found(): | CODE |
| LOW⚡ | tests/test_starlette_exception.py | 68 | def test_no_body_status_code_exception_handlers(): | CODE |
| LOW⚡ | tests/test_starlette_exception.py | 74 | def test_no_body_status_code_with_detail_exception_handlers(): | CODE |
| LOW | tests/test_multi_body_errors.py | 40 | def test_jsonable_encoder_requiring_error(): | CODE |
| LOW | tests/test_multi_body_errors.py | 56 | def test_put_incorrect_body_multiple(): | CODE |
| LOW⚡ | tests/test_security_http_digest_description.py | 19 | def test_security_http_digest(): | CODE |
| LOW⚡ | tests/test_security_http_digest_description.py | 25 | def test_security_http_digest_no_credentials(): | CODE |
| LOW⚡ | tests/test_security_http_digest_description.py | 32 | def test_security_http_digest_incorrect_scheme_credentials(): | CODE |
| LOW | tests/test_union_body_discriminator_annotated.py | 48 | def test_union_body_discriminator_assignment(client: TestClient) -> None: | CODE |
| LOW | tests/test_union_body_discriminator_annotated.py | 54 | def test_union_body_discriminator_annotated(client: TestClient) -> None: | CODE |
| LOW | tests/test_security_oauth2.py | 64 | def test_strict_login_no_data(): | CODE |
| LOW | tests/test_security_oauth2.py | 91 | def test_strict_login_no_grant_type(): | CODE |
| LOW | tests/test_security_oauth2.py | 114 | def test_strict_login_incorrect_grant_type(grant_type: str): | CODE |
| LOW | tests/test_security_oauth2.py | 133 | def test_strict_login_correct_grant_type(): | CODE |
| LOW⚡ | tests/test_security_http_basic_optional.py | 29 | def test_security_http_basic_no_credentials(): | CODE |
| LOW⚡ | tests/test_security_http_basic_optional.py | 35 | def test_security_http_basic_invalid_credentials(): | CODE |
| LOW⚡ | tests/test_security_http_basic_optional.py | 44 | def test_security_http_basic_non_basic_credentials(): | CODE |
| LOW⚡ | tests/test_response_model_invalid.py | 10 | def test_invalid_response_model_raises(): | CODE |
| LOW⚡ | tests/test_response_model_invalid.py | 19 | def test_invalid_response_model_sub_type_raises(): | CODE |
| LOW⚡ | tests/test_response_model_invalid.py | 28 | def test_invalid_response_model_in_responses_raises(): | CODE |
| LOW⚡ | tests/test_response_model_invalid.py | 37 | def test_invalid_response_model_sub_type_in_responses_raises(): | CODE |
| LOW | tests/test_dependency_yield_scope.py | 54 | def get_named_regular_func_session(session: SessionFuncDep) -> Any: | CODE |
| LOW | tests/test_dependency_yield_scope.py | 128 | def get_regular_function_scope(sessions: RegularSessionsDep) -> Any: | CODE |
| LOW⚡ | tests/test_dependency_yield_scope.py | 193 | def test_named_function_scope() -> None: | CODE |
| LOW⚡ | tests/test_dependency_yield_scope.py | 201 | def test_regular_function_scope() -> None: | CODE |
| LOW⚡ | tests/test_dependency_yield_scope.py | 209 | def test_router_level_dep_scope_function() -> None: | CODE |
| LOW⚡ | tests/test_dependency_yield_scope.py | 215 | def test_router_level_dep_scope_request() -> None: | CODE |
| LOW⚡ | tests/test_dependency_yield_scope.py | 222 | def test_app_level_dep_scope_function() -> None: | CODE |
| LOW | tests/test_dependency_yield_scope.py | 235 | def test_app_level_dep_scope_request() -> None: | CODE |
| LOW | tests/test_multi_query_errors.py | 22 | def test_multi_query_incorrect(): | CODE |
| LOW | tests/test_response_change_status_code.py | 23 | def test_dependency_set_status_code(): | CODE |
| LOW⚡ | tests/test_forms_from_non_typing_sequences.py | 25 | def test_python_list_param_as_form(): | CODE |
| LOW⚡ | tests/test_forms_from_non_typing_sequences.py | 33 | def test_python_set_param_as_form(): | CODE |
| LOW⚡ | tests/test_forms_from_non_typing_sequences.py | 41 | def test_python_tuple_param_as_form(): | CODE |
| LOW⚡ | tests/test_strict_content_type_app_level.py | 24 | def test_default_strict_rejects_no_content_type(): | CODE |
| LOW⚡ | tests/test_strict_content_type_app_level.py | 29 | def test_default_strict_accepts_json_content_type(): | CODE |
| LOW⚡ | tests/test_strict_content_type_app_level.py | 35 | def test_lax_accepts_no_content_type(): | CODE |
| LOW⚡ | tests/test_strict_content_type_app_level.py | 41 | def test_lax_accepts_json_content_type(): | CODE |
| LOW | tests/test_security_scopes_dont_propagate.py | 38 | def test_security_scopes_dont_propagate(): | CODE |
| LOW | tests/test_default_response_class_router.py | 202 | def test_router_b_a_c_override(): | CODE |
| LOW | tests/test_frontend.py | 29 | def test_frontend_exact_prefix_path_serves_index(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 41 | def test_apirouter_frontend_with_router_prefix_and_frontend_subpath(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 55 | def test_frontend_fallback_rejects_invalid_fallback(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 64 | def test_index_fallback_ignores_invalid_q_value(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 78 | def test_frontend_static_files_lookup_errors(monkeypatch, tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 116 | def test_frontend_route_group_helpers(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 156 | def test_included_low_priority_routes_cache_is_reused(): | CODE |
| LOW | tests/test_frontend.py | 180 | def test_low_priority_api_route_handles_with_context(): | CODE |
| LOW | tests/test_frontend.py | 196 | def test_included_low_priority_api_route_handles_with_context(): | CODE |
| LOW | tests/test_frontend.py | 214 | def test_normal_route_partial_match_returns_before_frontend(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 235 | def test_normal_route_partial_match_wins_before_frontend(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 270 | def test_app_frontend_dependencies_protect_root_asset_and_fallback(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 305 | def test_apirouter_frontend_dependencies_protect_prefixed_frontend(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 338 | def test_included_frontend_does_not_block_url_path_for(tmp_path: Path): | CODE |
| LOW | tests/test_frontend.py | 366 | def test_include_router_frontend_dependencies_apply_in_nested_order(tmp_path: Path): | CODE |
| 1354 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM⚡ | …s/test_request_params/test_cookie/test_required_str.py | 176 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_cookie/test_required_str.py | 282 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_cookie/test_required_str.py | 12 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_cookie/test_required_str.py | 79 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_cookie/test_optional_str.py | 150 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_cookie/test_optional_str.py | 233 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_cookie/test_optional_str.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_cookie/test_optional_str.py | 72 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_form/test_list.py | 183 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_form/test_list.py | 294 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_form/test_list.py | 13 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_form/test_list.py | 84 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …sts/test_request_params/test_form/test_required_str.py | 170 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …sts/test_request_params/test_form/test_required_str.py | 277 | # ===================================================================================== | COMMENT |
| MEDIUM | …sts/test_request_params/test_form/test_required_str.py | 13 | # ===================================================================================== | COMMENT |
| MEDIUM | …sts/test_request_params/test_form/test_required_str.py | 80 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …sts/test_request_params/test_form/test_optional_str.py | 148 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …sts/test_request_params/test_form/test_optional_str.py | 231 | # ===================================================================================== | COMMENT |
| MEDIUM | …sts/test_request_params/test_form/test_optional_str.py | 12 | # ===================================================================================== | COMMENT |
| MEDIUM | …sts/test_request_params/test_form/test_optional_str.py | 72 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …ts/test_request_params/test_form/test_optional_list.py | 158 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …ts/test_request_params/test_form/test_optional_list.py | 244 | # ===================================================================================== | COMMENT |
| MEDIUM | …ts/test_request_params/test_form/test_optional_list.py | 12 | # ===================================================================================== | COMMENT |
| MEDIUM | …ts/test_request_params/test_form/test_optional_list.py | 77 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_header/test_list.py | 180 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_header/test_list.py | 287 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_header/test_list.py | 12 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_header/test_list.py | 82 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_header/test_required_str.py | 170 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_header/test_required_str.py | 274 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_header/test_required_str.py | 12 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_header/test_required_str.py | 78 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_header/test_optional_str.py | 147 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …s/test_request_params/test_header/test_optional_str.py | 228 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_header/test_optional_str.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM | …s/test_request_params/test_header/test_optional_str.py | 71 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …/test_request_params/test_header/test_optional_list.py | 159 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …/test_request_params/test_header/test_optional_list.py | 242 | # ===================================================================================== | COMMENT |
| MEDIUM | …/test_request_params/test_header/test_optional_list.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM | …/test_request_params/test_header/test_optional_list.py | 78 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_required.py | 87 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_required.py | 188 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_required.py | 300 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_file/test_required.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_file/test_list.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_file/test_list.py | 90 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_list.py | 194 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_list.py | 309 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_optional.py | 79 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_optional.py | 165 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_file/test_optional.py | 256 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_file/test_optional.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …ts/test_request_params/test_file/test_optional_list.py | 87 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …ts/test_request_params/test_file/test_optional_list.py | 179 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | …ts/test_request_params/test_file/test_optional_list.py | 273 | # ===================================================================================== | COMMENT |
| MEDIUM | …ts/test_request_params/test_file/test_optional_list.py | 11 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_body/test_list.py | 182 | # ===================================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_request_params/test_body/test_list.py | 293 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_body/test_list.py | 13 | # ===================================================================================== | COMMENT |
| MEDIUM | tests/test_request_params/test_body/test_list.py | 85 | # ===================================================================================== | COMMENT |
| 46 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_security_oauth2.py | 3 | CODE | |
| LOW | tests/test_stringified_annotation_dependency.py | 1 | CODE | |
| LOW | …pydanticv2_dataclasses_uuid_stringified_annotations.py | 1 | CODE | |
| LOW | tests/test_stringified_annotations_simple.py | 1 | CODE | |
| LOW | fastapi/responses.py | 5 | CODE | |
| LOW | fastapi/responses.py | 6 | CODE | |
| LOW | fastapi/responses.py | 7 | CODE | |
| LOW | fastapi/responses.py | 9 | CODE | |
| LOW | fastapi/responses.py | 10 | CODE | |
| LOW | fastapi/responses.py | 11 | CODE | |
| LOW | fastapi/responses.py | 12 | CODE | |
| LOW | fastapi/templating.py | 1 | CODE | |
| LOW | fastapi/websockets.py | 1 | CODE | |
| LOW | fastapi/websockets.py | 2 | CODE | |
| LOW | fastapi/websockets.py | 3 | CODE | |
| LOW | fastapi/concurrency.py | 8 | CODE | |
| LOW | fastapi/concurrency.py | 10 | CODE | |
| LOW | fastapi/__init__.py | 5 | CODE | |
| LOW | fastapi/__init__.py | 7 | CODE | |
| LOW | fastapi/__init__.py | 8 | CODE | |
| LOW | fastapi/__init__.py | 9 | CODE | |
| LOW | fastapi/__init__.py | 10 | CODE | |
| LOW | fastapi/__init__.py | 11 | CODE | |
| LOW | fastapi/__init__.py | 12 | CODE | |
| LOW | fastapi/__init__.py | 13 | CODE | |
| LOW | fastapi/__init__.py | 14 | CODE | |
| LOW | fastapi/__init__.py | 15 | CODE | |
| LOW | fastapi/__init__.py | 16 | CODE | |
| LOW | fastapi/__init__.py | 17 | CODE | |
| LOW | fastapi/__init__.py | 18 | CODE | |
| LOW | fastapi/__init__.py | 19 | CODE | |
| LOW | fastapi/__init__.py | 20 | CODE | |
| LOW | fastapi/__init__.py | 21 | CODE | |
| LOW | fastapi/__init__.py | 22 | CODE | |
| LOW | fastapi/__init__.py | 23 | CODE | |
| LOW | fastapi/__init__.py | 24 | CODE | |
| LOW | fastapi/__init__.py | 25 | CODE | |
| LOW | fastapi/types.py | 7 | CODE | |
| LOW | fastapi/staticfiles.py | 1 | CODE | |
| LOW | fastapi/utils.py | 23 | CODE | |
| LOW | fastapi/testclient.py | 1 | CODE | |
| LOW | fastapi/requests.py | 1 | CODE | |
| LOW | fastapi/requests.py | 2 | CODE | |
| LOW | fastapi/datastructures.py | 12 | CODE | |
| LOW | fastapi/datastructures.py | 13 | CODE | |
| LOW | fastapi/datastructures.py | 14 | CODE | |
| LOW | fastapi/datastructures.py | 16 | CODE | |
| LOW | fastapi/datastructures.py | 17 | CODE | |
| LOW | fastapi/middleware/gzip.py | 1 | CODE | |
| LOW | fastapi/middleware/cors.py | 1 | CODE | |
| LOW | fastapi/middleware/__init__.py | 1 | CODE | |
| LOW | fastapi/middleware/httpsredirect.py | 1 | CODE | |
| LOW | fastapi/middleware/trustedhost.py | 1 | CODE | |
| LOW | fastapi/middleware/wsgi.py | 1 | CODE | |
| LOW | fastapi/security/__init__.py | 1 | CODE | |
| LOW | fastapi/security/__init__.py | 2 | CODE | |
| LOW | fastapi/security/__init__.py | 3 | CODE | |
| LOW | fastapi/security/__init__.py | 4 | CODE | |
| LOW | fastapi/security/__init__.py | 5 | CODE | |
| LOW | fastapi/security/__init__.py | 6 | CODE | |
| 44 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_union_forms.py | 31 | "/form-union/", data={"name": "John Doe", "email": "john@example.com"} | CODE |
| LOW | tests/test_union_forms.py | 35 | "received": {"name": "John Doe", "email": "john@example.com"} | CODE |
| LOW | tests/test_stringified_annotation_dependency.py | 16 | return ["John Doe", "Jane Doe"] | CODE |
| LOW | tests/test_stringified_annotation_dependency.py | 16 | return ["John Doe", "Jane Doe"] | CODE |
| LOW | tests/test_stringified_annotation_dependency.py | 46 | assert response.json() == ["John Doe", "Jane Doe"] | CODE |
| LOW | tests/test_stringified_annotation_dependency.py | 46 | assert response.json() == ["John Doe", "Jane Doe"] | CODE |
| LOW | tests/test_get_model_definitions_formfeed_escape.py | 32 | address=Address(line_1="123 Main St", city="Anytown", state_province="CA"), | CODE |
| LOW | tests/test_get_model_definitions_formfeed_escape.py | 45 | "line_1": "123 Main St", | CODE |
| LOW | …rial/test_extra_models/test_tutorial001_tutorial002.py | 32 | "full_name": "John Doe", | CODE |
| LOW | …rial/test_extra_models/test_tutorial001_tutorial002.py | 39 | "full_name": "John Doe", | CODE |
| LOW | tests/test_tutorial/test_settings/test_app01.py | 26 | monkeypatch.setenv("ADMIN_EMAIL", "admin@example.com") | CODE |
| LOW | tests/test_tutorial/test_settings/test_app01.py | 54 | "admin_email": "admin@example.com", | CODE |
| LOW⚡ | tests/test_tutorial/test_settings/test_app03.py | 28 | monkeypatch.setenv("ADMIN_EMAIL", "admin@example.com") | CODE |
| LOW⚡ | tests/test_tutorial/test_settings/test_app03.py | 31 | assert settings.admin_email == "admin@example.com" | CODE |
| LOW⚡ | tests/test_tutorial/test_settings/test_app03.py | 36 | monkeypatch.setenv("ADMIN_EMAIL", "admin@example.com") | CODE |
| LOW⚡ | tests/test_tutorial/test_settings/test_app03.py | 42 | "admin_email": "admin@example.com", | CODE |
| LOW | tests/test_tutorial/test_settings/test_tutorial001.py | 10 | monkeypatch.setenv("ADMIN_EMAIL", "admin@example.com") | CODE |
| LOW | tests/test_tutorial/test_settings/test_tutorial001.py | 21 | "admin_email": "admin@example.com", | CODE |
| LOW | tests/test_tutorial/test_settings/test_app02.py | 33 | monkeypatch.setenv("ADMIN_EMAIL", "admin@example.com") | CODE |
| LOW | …ts/test_tutorial/test_python_types/test_tutorial010.py | 5 | assert get_person_name(Person("John Doe")) == "John Doe" | CODE |
| LOW | …ts/test_tutorial/test_python_types/test_tutorial011.py | 22 | "id=123 name='John Doe' signup_ts=datetime.datetime(2017, 6, 1, 12, 22) friends=[1, 2, 3]", | CODE |
| LOW | …rial/test_python_types/test_tutorial001_tutorial002.py | 18 | mock_print.assert_called_with("John Doe") | CODE |
| LOW | …tutorial/test_body_multiple_params/test_tutorial002.py | 33 | "user": {"username": "johndoe", "full_name": "John Doe"}, | CODE |
| LOW | …tutorial/test_body_multiple_params/test_tutorial002.py | 45 | "user": {"username": "johndoe", "full_name": "John Doe"}, | CODE |
| LOW⚡ | …tutorial/test_body_multiple_params/test_tutorial002.py | 159 | "user": {"full_name": "John Doe"}, | CODE |
| LOW⚡ | …tutorial/test_body_multiple_params/test_tutorial002.py | 166 | "input": {"full_name": "John Doe"}, | CODE |
| LOW | tests/test_tutorial/test_security/test_tutorial002.py | 36 | "full_name": "John Doe", | CODE |
| LOW | tests/test_tutorial/test_security/test_tutorial003.py | 56 | "full_name": "John Doe", | CODE |
| LOW | tests/test_tutorial/test_security/test_tutorial004.py | 75 | "full_name": "John Doe", | CODE |
| LOW | tests/test_tutorial/test_security/test_tutorial005.py | 96 | "full_name": "John Doe", | CODE |
| LOW | docs/zh-hant/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/zh-hant/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/zh-hant/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/ja/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/ja/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/ja/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/ru/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/ru/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/ru/docs/tutorial/security/simple-oauth2.md | 231 | "full_name": "John Doe", | CODE |
| LOW | docs/pt/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/pt/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/pt/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/zh/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/zh/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/zh/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/uk/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/uk/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/uk/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/hi/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/de/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/de/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/de/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/ko/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/ko/docs/tutorial/security/oauth2-jwt.md | 231 | "full_name": "John Doe", | CODE |
| LOW | docs/ko/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/fr/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/fr/docs/tutorial/security/oauth2-jwt.md | 230 | "full_name": "John Doe", | CODE |
| LOW | docs/fr/docs/tutorial/security/simple-oauth2.md | 247 | "full_name": "John Doe", | CODE |
| LOW | docs/es/docs/features.md | 55 | my_user: User = User(id=3, name="John Doe", joined="2018-07-19") | CODE |
| LOW | docs/es/docs/tutorial/security/oauth2-jwt.md | 231 | "full_name": "John Doe", | CODE |
| 17 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | …m_response/test_tutorial002_tutorial003_tutorial004.py | 0 | <html> <head> <title>some html in here</title> </head> <body> <h1>look ma! html!</h1> </body> </html> | STRING |
| HIGH | docs_src/custom_response/tutorial004_py310.py | 0 | <html> <head> <title>some html in here</title> </head> <body> <h1>look ma! html!</h1> </body> </html> | STRING |
| HIGH | docs_src/custom_response/tutorial002_py310.py | 0 | <html> <head> <title>some html in here</title> </head> <body> <h1>look ma! html!</h1> </body> </html> | STRING |
| HIGH | docs_src/custom_response/tutorial003_py310.py | 0 | <html> <head> <title>some html in here</title> </head> <body> <h1>look ma! html!</h1> </body> </html> | STRING |
| HIGH | …eration_configurations/test_tutorial003_tutorial004.py | 0 | create an item with all the information: - **name**: each item must have a name - **description**: a long description - | STRING |
| HIGH | …_src/path_operation_configuration/tutorial005_py310.py | 0 | create an item with all the information: - **name**: each item must have a name - **description**: a long description - | STRING |
| HIGH | …_src/path_operation_configuration/tutorial004_py310.py | 0 | create an item with all the information: - **name**: each item must have a name - **description**: a long description - | STRING |
| HIGH | …_operation_advanced_configuration/tutorial004_py310.py | 0 | create an item with all the information: - **name**: each item must have a name - **description**: a long description - | STRING |
| HIGH | fastapi/security/open_id_connect_url.py | 0 | security scheme description. it will be included in the generated openapi (e.g. visible at `/docs`). | STRING |
| HIGH | fastapi/security/oauth2.py | 0 | security scheme description. it will be included in the generated openapi (e.g. visible at `/docs`). | STRING |
| HIGH | fastapi/security/api_key.py | 0 | security scheme description. it will be included in the generated openapi (e.g. visible at `/docs`). | STRING |
| HIGH | fastapi/security/http.py | 0 | security scheme description. it will be included in the generated openapi (e.g. visible at `/docs`). | STRING |
| HIGH | docs_src/request_files/tutorial002_an_py310.py | 0 | <body> <form action="/files/" enctype="multipart/form-data" method="post"> <input name="files" type="file" multiple> <in | STRING |
| HIGH | docs_src/request_files/tutorial003_an_py310.py | 0 | <body> <form action="/files/" enctype="multipart/form-data" method="post"> <input name="files" type="file" multiple> <in | STRING |
| HIGH | docs_src/request_files/tutorial002_py310.py | 0 | <body> <form action="/files/" enctype="multipart/form-data" method="post"> <input name="files" type="file" multiple> <in | STRING |
| HIGH | docs_src/request_files/tutorial003_py310.py | 0 | <body> <form action="/files/" enctype="multipart/form-data" method="post"> <input name="files" type="file" multiple> <in | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_dependency_after_yield_streaming.py | 53 | CODE | |
| LOW | fastapi/params.py | 29 | CODE | |
| LOW | fastapi/params.py | 140 | CODE | |
| LOW | fastapi/params.py | 224 | CODE | |
| LOW | fastapi/params.py | 306 | CODE | |
| LOW | fastapi/params.py | 390 | CODE | |
| LOW | fastapi/params.py | 470 | CODE | |
| LOW | fastapi/params.py | 582 | CODE | |
| LOW | fastapi/params.py | 664 | CODE | |
| LOW | fastapi/applications.py | 58 | CODE | |
| LOW | fastapi/applications.py | 1165 | CODE | |
| LOW | fastapi/applications.py | 1295 | CODE | |
| LOW | fastapi/applications.py | 1435 | CODE | |
| LOW | fastapi/applications.py | 1640 | CODE | |
| LOW | fastapi/applications.py | 2013 | CODE | |
| LOW | fastapi/applications.py | 2391 | CODE | |
| LOW | fastapi/applications.py | 2769 | CODE | |
| LOW | fastapi/applications.py | 3142 | CODE | |
| LOW | fastapi/applications.py | 3515 | CODE | |
| LOW | fastapi/applications.py | 3888 | CODE | |
| LOW | fastapi/applications.py | 4266 | CODE | |
| LOW | fastapi/encoders.py | 129 | CODE | |
| LOW | fastapi/routing.py | 293 | CODE | |
| LOW | fastapi/routing.py | 367 | CODE | |
| LOW | fastapi/routing.py | 946 | CODE | |
| LOW | fastapi/routing.py | 1146 | CODE | |
| LOW | fastapi/routing.py | 1291 | CODE | |
| LOW | fastapi/routing.py | 2237 | CODE | |
| LOW | fastapi/routing.py | 2838 | CODE | |
| LOW | fastapi/routing.py | 2922 | CODE | |
| LOW | fastapi/routing.py | 3082 | CODE | |
| LOW | fastapi/routing.py | 3271 | CODE | |
| LOW | fastapi/routing.py | 3648 | CODE | |
| LOW | fastapi/routing.py | 4030 | CODE | |
| LOW | fastapi/routing.py | 4412 | CODE | |
| LOW | fastapi/routing.py | 4789 | CODE | |
| LOW | fastapi/routing.py | 5166 | CODE | |
| LOW | fastapi/routing.py | 5548 | CODE | |
| LOW | fastapi/routing.py | 5930 | CODE | |
| LOW | fastapi/param_functions.py | 13 | CODE | |
| LOW | fastapi/param_functions.py | 357 | CODE | |
| LOW | fastapi/param_functions.py | 701 | CODE | |
| LOW | fastapi/param_functions.py | 1018 | CODE | |
| LOW | fastapi/param_functions.py | 1323 | CODE | |
| LOW | fastapi/param_functions.py | 1653 | CODE | |
| LOW | fastapi/param_functions.py | 1968 | CODE | |
| LOW | fastapi/openapi/utils.py | 523 | CODE | |
| LOW | …_operation_advanced_configuration/tutorial006_py310.py | 41 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | fastapi/encoders.py | 129 | CODE | |
| LOW | fastapi/routing.py | 367 | CODE | |
| LOW | fastapi/routing.py | 946 | CODE | |
| LOW | fastapi/routing.py | 398 | CODE | |
| LOW | fastapi/routing.py | 1701 | CODE | |
| LOW | fastapi/routing.py | 2107 | CODE | |
| LOW | fastapi/routing.py | 2760 | CODE | |
| LOW | fastapi/routing.py | 3082 | CODE | |
| LOW | fastapi/routing.py | 516 | CODE | |
| LOW | fastapi/routing.py | 551 | CODE | |
| LOW | fastapi/routing.py | 581 | CODE | |
| LOW | fastapi/dependencies/utils.py | 286 | CODE | |
| LOW | fastapi/dependencies/utils.py | 362 | CODE | |
| LOW | fastapi/dependencies/utils.py | 393 | CODE | |
| LOW | fastapi/dependencies/utils.py | 598 | CODE | |
| LOW | fastapi/dependencies/utils.py | 784 | CODE | |
| LOW | fastapi/dependencies/utils.py | 916 | CODE | |
| LOW | fastapi/openapi/utils.py | 107 | CODE | |
| LOW | fastapi/openapi/utils.py | 260 | CODE | |
| LOW | fastapi/openapi/utils.py | 523 | CODE | |
| LOW | fastapi/_compat/shared.py | 109 | CODE | |
| LOW | fastapi/_compat/v2.py | 446 | CODE | |
| LOW | scripts/contributors.py | 175 | CODE | |
| LOW | scripts/notify_translations.py | 306 | CODE | |
| LOW | scripts/doc_parsing_utils.py | 141 | CODE | |
| LOW | scripts/doc_parsing_utils.py | 482 | CODE | |
| LOW | scripts/doc_parsing_utils.py | 570 | CODE | |
| LOW | scripts/docs.py | 208 | CODE | |
| LOW | scripts/docs.py | 600 | CODE | |
| LOW | scripts/docs.py | 727 | CODE | |
| LOW | scripts/docs.py | 837 | CODE | |
| LOW | scripts/people.py | 268 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_ws_router.py | 220 | except Exception as e: # pragma: no cover | CODE |
| LOW | tests/test_ws_router.py | 245 | except Exception as e: | CODE |
| MEDIUM | tests/test_ws_router.py | 217 | def catcher(websocket, call_next): | CODE |
| LOW⚡ | tests/test_validation_error_context.py | 91 | except Exception: | CODE |
| LOW⚡ | tests/test_validation_error_context.py | 104 | except Exception: | CODE |
| LOW⚡ | tests/test_validation_error_context.py | 118 | except Exception: | CODE |
| LOW⚡ | tests/test_validation_error_context.py | 131 | except Exception: | CODE |
| LOW⚡ | tests/test_validation_error_context.py | 145 | except Exception: | CODE |
| LOW | fastapi/concurrency.py | 30 | except Exception as e: | CODE |
| LOW | fastapi/encoders.py | 346 | except Exception as e: | CODE |
| LOW | fastapi/encoders.py | 351 | except Exception as e: | CODE |
| LOW | fastapi/routing.py | 286 | except Exception: | CODE |
| LOW | fastapi/routing.py | 461 | except Exception as e: | CODE |
| MEDIUM | scripts/translation_fixer.py | 97 | print(f"Error processing {path}: {e}") | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | docs/ja/docs/tutorial/first-steps.md | 384 | ### Step 5: コンテンツの返信 { #step-5-return-the-content } | COMMENT |
| LOW | docs/ja/docs/tutorial/first-steps.md | 394 | ### Step 6: デプロイする { #step-6-deploy-it } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 225 | ### Step 1: import `FastAPI` { #step-1-import-fastapi } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 239 | ### Step 2: create a `FastAPI` "instance" { #step-2-create-a-fastapi-instance } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 247 | ### Step 3: create a *path operation* { #step-3-create-a-path-operation } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 356 | ### Step 4: define the **path operation function** { #step-4-define-the-path-operation-function } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 384 | ### Step 5: return the content { #step-5-return-the-content } | COMMENT |
| LOW | docs/en/docs/tutorial/first-steps.md | 394 | ### Step 6: Deploy it { #step-6-deploy-it } | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | docs_src/websockets_/tutorial002_an_py310.py | 35 | var ws = null; | CODE |
| HIGH | docs_src/websockets_/tutorial002_py310.py | 33 | var ws = null; | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | …s/test_tutorial/test_sql_databases/test_tutorial002.py | 63 | # Create a hero | COMMENT |
| MEDIUM | …s/test_tutorial/test_sql_databases/test_tutorial001.py | 63 | # Create a hero | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | docs/en/data/sponsors.yml | 62 | # title: Learn to build high-quality web apps with best practices | COMMENT |
| MEDIUM | fastapi/routing.py | 340 | # facilitate profiling endpoints, since inner functions are harder to profile. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_schema_extra_examples.py | 61 | # def form_examples( | COMMENT |
| LOW | tests/test_request_params/test_cookie/test_list.py | 1 | # Currently, there is no way to pass multiple cookies with the same name. | COMMENT |
| LOW | …/test_request_params/test_cookie/test_optional_list.py | 1 | # Currently, there is no way to pass multiple cookies with the same name. | COMMENT |
| LOW | fastapi/applications.py | 1041 | ), | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | fastapi/routing.py | 866 | def _update_scope(scope: Scope, child_scope: Scope) -> None: | CODE |
| LOW | scripts/docs.py | 421 | def update_languages() -> None: | STRING |
| LOW | scripts/docs.py | 703 | def update_docs_includes_py39_to_py310() -> None: | STRING |
| LOW | scripts/people.py | 65 | def update_request_info(self, cost: int, remaining: int, reset_at: str) -> None: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | fastapi/.agents/skills/fastapi/SKILL.md | 15 | * Dependencies: use `Annotated[..., Depends(...)]`; see [Dependency Injection](#dependency-injection) and [the dependenc | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | fastapi/dependencies/utils.py | 879 | # Check if it's a Union type (covers both typing.Union and types.UnionType in Python 3.10+) | COMMENT |
| LOW | scripts/docs.py | 767 | # Check if the _an counterpart (or non-_an counterpart) is referenced. | STRING |