Repository Analysis

aio-libs/aiohttp

Asynchronous HTTP client/server framework for asyncio and Python

23.7 Moderate AI signal View on GitHub
23.7
Adjusted Score
23.7
Raw Score
100%
Time Factor
2026-05-30
Last Push
16,432
Stars
Python
Language
99,285
Lines of Code
225
Files
2603
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 19MEDIUM 81LOW 2503

Pattern Findings

2603 matches across 16 categories. Click a row to expand file-level details.

Hyper-Verbose Identifiers1951 hits · 1532 pts
SeverityFileLineSnippet
LOWaiohttp/web_ws.py240 def _handle_ping_pong_exception(self, exc: BaseException) -> None:
LOWaiohttp/web_ws.py571 def _set_code_close_transport(self, code: int) -> None:
LOWaiohttp/client_middlewares.py35 async def single_middleware_handler(req: ClientRequest) -> ClientResponse:
LOWaiohttp/multipart.py77def parse_content_disposition(
LOWaiohttp/multipart.py180def content_disposition_filename(
LOWaiohttp/multipart.py510 def _apply_content_transfer_decoding(self, data: bytes) -> bytes:
LOWaiohttp/multipart.py827 async def _read_until_first_boundary(self) -> None:
LOWaiohttp/web_response.py316 def _generate_content_type_header(
LOWaiohttp/client_ws.py213 def _handle_ping_pong_exception(self, exc: BaseException) -> None:
LOWaiohttp/tracing.py136 def on_response_chunk_received(
LOWaiohttp/tracing.py158 def on_connection_queued_start(
LOWaiohttp/tracing.py170 def on_connection_create_start(
LOWaiohttp/tracing.py368 async def send_response_chunk_received(
LOWaiohttp/tracing.py416 async def send_connection_queued_start(self) -> None:
LOWaiohttp/tracing.py421 async def send_connection_queued_end(self) -> None:
LOWaiohttp/tracing.py426 async def send_connection_create_start(self) -> None:
LOWaiohttp/tracing.py431 async def send_connection_create_end(self) -> None:
LOWaiohttp/tracing.py436 async def send_connection_reuseconn(self) -> None:
LOWaiohttp/tracing.py441 async def send_dns_resolvehost_start(self, host: str) -> None:
LOWaiohttp/web_exceptions.py499def _initialize_default_reason() -> None:
LOWaiohttp/web_middlewares.py45def normalize_path_middleware(
LOWaiohttp/streams.py301 def begin_http_chunk_receiving(self) -> None:
LOWaiohttp/web_protocol.py120class RequestHandler(BaseProtocol, Generic[_Request]):
LOWaiohttp/client.py692 async def _connect_and_send_request(
LOWaiohttp/web_urldispatcher.py635 def _resolve_path_to_response(self, unresolved_path: Path) -> StreamResponse:
LOWaiohttp/client_proto.py32class ResponseHandler(BaseProtocol, DataQueue[tuple[RawResponseMessage, StreamReader]]):
LOWaiohttp/payload.py472 def _set_or_restore_start_position(self) -> None:
LOWaiohttp/client_reqrep.py85def _gen_default_accept_encoding() -> str:
LOWaiohttp/client_reqrep.py1129 def _update_transfer_encoding(self) -> None:
LOWaiohttp/connector.py553 def _update_proxy_auth_header_and_build_proxy_req(
LOWaiohttp/connector.py636 async def _wait_for_available_connection(
LOWaiohttp/connector.py1134 async def _resolve_host_with_throttle(
LOWaiohttp/connector.py1404 def _convert_hosts_to_addr_infos(
LOWaiohttp/connector.py1425 async def _create_direct_connection(
LOWaiohttp/web_fileresponse.py224 def _get_file_path_stat_encoding(
LOWaiohttp/_cookie_helpers.py85def preserve_morsel_with_coded_value(cookie: Morsel[str]) -> Morsel[str]:
LOWaiohttp/http_writer.py132 def _send_headers_with_payload(
LOWaiohttp/helpers.py409def content_disposition_header(
LOWaiohttp/helpers.py1142def should_remove_content_length(method: str, code: int) -> bool:
LOWaiohttp/http_parser.py1154 def begin_http_chunk_receiving(self) -> None:
LOWaiohttp/abc.py189 def update_cookies_from_headers(
LOWaiohttp/_websocket/writer.py190 def _send_compressed_frame_sync(
LOWaiohttp/_websocket/writer.py218 async def _send_compressed_frame_async_locked(
LOWtests/test_connector.py2803async def test_close_cancels_cleanup_handle(key: ConnectionKey) -> None:
LOWtests/test_connector.py2811async def test_close_cancels_resolve_host(make_client_request: _RequestMaker) -> None:
LOWtests/test_connector.py3185async def test_close_cancels_cleanup_closed_handle() -> None:
LOWtests/test_connector.py3192async def test_ctor_with_default_loop() -> None:
LOWtests/test_connector.py3199async def test_base_connector_allows_high_level_protocols() -> None:
LOWtests/test_connector.py3722async def test_limit_per_host_property() -> None:
LOWtests/test_connector.py3729async def test_limit_property_default() -> None:
LOWtests/test_connector.py3735async def test_limit_per_host_property_default() -> None:
LOWtests/test_connector.py3741async def test_force_close_and_explicit_keep_alive() -> None:
LOWtests/test_connector.py4461async def test_connector_does_not_remove_needed_waiters(
LOWtests/test_connector.py4471 async def await_connection_and_check_waiters() -> None:
LOWtests/test_connector.py4479 async def allow_connection_and_add_dummy_waiter() -> None:
LOWtests/test_connector.py169async def test_connection_del_loop_debug() -> None:
LOWtests/test_connector.py191def test_connection_del_loop_closed(
LOWtests/test_connector.py236async def test_del_with_scheduled_cleanup(key: ConnectionKey) -> None:
LOWtests/test_connector.py265def test_del_with_closed_loop(
LOWtests/test_connector.py308async def test_async_context_manager() -> None:
1891 more matches not shown…
Self-Referential Comments70 hits · 222 pts
SeverityFileLineSnippet
MEDIUMaiohttp/client_middlewares.py44 # Create a new closure that captures the current state
MEDIUMaiohttp/resolver.py199 # Create a new resolver and client set for this loop if it doesn't exist
MEDIUMaiohttp/connector.py1326 tls_proto = self._factory() # Create a brand new proto for TLS
MEDIUMaiohttp/client_middleware_digest_auth.py335 # Define a dict mapping of header fields to their values
MEDIUMaiohttp/_websocket/writer.py96 # Create a task to shield from cancellation
MEDIUMtests/test_connector.py2311 # Create a mock SSL protocol
MEDIUMtests/test_connector.py2341 # Create a mock non-SSL protocol
MEDIUMtests/test_connector.py4685 # Create a connect tunnel connection
MEDIUMtests/test_client_functional.py694 # Create a BytesPayload directly - this ensures we test the path
MEDIUMtests/test_client_functional.py742 # Create a streaming response that continuously sends data
MEDIUMtests/test_client_functional.py765 # Create a background task that continuously reads data
MEDIUMtests/test_client_functional.py2411 # Create a highly compressible payload.
MEDIUMtests/test_client_functional.py2443 # Create a highly compressible payload
MEDIUMtests/test_client_functional.py2474 # Create a highly compressible payload.
MEDIUMtests/test_client_functional.py4616 # Create an async generator of data
MEDIUMtests/test_client_functional.py5247 # Create a mocked payload to verify close() is called
MEDIUMtests/test_client_functional.py5277 # Create a mocked payload to verify close() is called
MEDIUMtests/test_client_functional.py5307 # Create a mocked payload to verify close() is called
MEDIUMtests/test_client_functional.py5334 # Create a mocked payload to verify close() is called
MEDIUMtests/test_client_functional.py5419 # Create a new client session with our fake resolver
MEDIUMtests/test_client_functional.py5525 # Create a test file
MEDIUMtests/test_client_functional.py5590 # Create a test file
MEDIUMtests/test_client_functional.py5663 # Create a test file
MEDIUMtests/test_websocket_parser.py39 # This method is overridden to allow for patching in tests.
MEDIUMtests/test_websocket_parser.py48 # This method is overridden to allow for patching in tests.
MEDIUMtests/test_client_request.py128 # Create a response to test request_info
MEDIUMtests/test_client_request.py150 # Create a response to test request_info
MEDIUMtests/test_client_request.py1132 # Create a BytesPayload which has a size property
MEDIUMtests/test_client_request.py1155 # Create a payload with a known size
MEDIUMtests/test_client_request.py1900 # Create an empty async generator
MEDIUMtests/test_client_request.py1922 # Create a mock payload that tracks if it was closed
MEDIUMtests/test_client_request.py2045 # Create a mock writer and connection
MEDIUMtests/test_client_request.py2049 # Create a request
MEDIUMtests/test_cookie_helpers.py48 # Create a cookie with a coded_value different from value
MEDIUMtests/test_cookiejar.py1425 # Create a shared cookie (no domain/path restrictions)
MEDIUMtests/test_cookiejar.py1553 # Create a truly shared cookie
MEDIUMtests/test_client_middleware_digest_auth.py257 # Create a modified challenge with an unsupported algorithm
MEDIUMtests/test_client_middleware_digest_auth.py273 # Create a challenge with the specific algorithm case
MEDIUMtests/test_client_middleware_digest_auth.py242 # Create a modified challenge with the test algorithm
MEDIUMtests/test_client_middleware_digest_auth.py293 # Create a challenge with the specific algorithm case
MEDIUMtests/test_client_middleware_digest_auth.py393 # Create the auth object
MEDIUMtests/test_client_middleware_digest_auth.py865 # Create a session that uses the digest auth middleware
MEDIUMtests/test_client_response.py1803 # Create a SimpleCookie with some cookies
MEDIUMtests/test_client_middleware.py804 # Create a simple server for the allowed request
MEDIUMtests/test_client_middleware.py945 # Create main server
MEDIUMtests/test_client_middleware.py1014 # Create main server
MEDIUMtests/test_payload.py1327 # Create a test file with known content
MEDIUMtests/test_payload.py374 # Create a large file that's multiple times larger than DEFAULT_CHUNK_SIZE
MEDIUMtests/test_payload.py418 # Create a custom file-like object that tracks read sizes
MEDIUMtests/test_payload.py448 # Create a large text file that's multiple times larger than DEFAULT_CHUNK_SIZE
MEDIUMtests/test_payload.py493 # Create a custom file-like object that tracks read sizes
MEDIUMtests/test_http_parser.py2757 # Create a large payload (3MiB) that compresses well
MEDIUMtests/test_proxy_functional.py963 # Create a minimal proxy server
MEDIUMtests/test_client_proto.py327 # Create a mock transport
MEDIUMtests/test_multipart.py1731 # Create a mock BodyPartReader
MEDIUMtests/test_multipart.py1737 # Create the payload
MEDIUMtests/test_web_urldispatcher.py276 # This file is below the symlink target and should not be reachable
MEDIUMtests/test_resolver.py449 # Create a second manager and check it's the same instance
MEDIUMtests/test_resolver.py466 # Create a mock AsyncResolver for testing
MEDIUMtests/test_resolver.py586 # Create a mock resolver that will be None when accessed
10 more matches not shown…
Unused Imports313 hits · 221 pts
SeverityFileLineSnippet
LOWaiohttp/multipart.py66
LOWaiohttp/web_response.py1
LOWaiohttp/web_response.py49
LOWaiohttp/test_utils.py19
LOWaiohttp/tracing.py5
LOWaiohttp/tracing.py12
LOWaiohttp/web_middlewares.py17
LOWaiohttp/web.py14
LOWaiohttp/web.py14
LOWaiohttp/web.py14
LOWaiohttp/web.py17
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
LOWaiohttp/web.py18
253 more matches not shown…
Over-Commented Block122 hits · 122 pts
SeverityFileLineSnippet
LOWsetup.cfg61# 2-minute per-test timeout so a hung test surfaces by name instead of taking
LOWsetup.cfg81 ignore:path is deprecated. Use files.. instead. Refer to https.//importlib-resources.readthedocs.io/en/latest/using.
LOWaiohttp/multipart.py941 def _boundary_value(self) -> str:
LOWaiohttp/web_urldispatcher.py981 # (though custom rules could match on other things). This means that
LOWaiohttp/client_middleware_digest_auth.py61 # +--|-|-|--|----|------|----|--||-----|-> maybe whitespace
LOWaiohttp/web_fileresponse.py301 if (ifrange := request.if_range) is None or file_mtime <= ifrange.timestamp():
LOWaiohttp/web_fileresponse.py341 # the byte range is interpreted as the remainder
LOWaiohttp/_websocket/writer.py81 # Non-compressed frames don't need lock or shield
LOWtests/test_web_urldispatcher.py261) -> None:
LOWrequirements/base-ft.txt1#
LOWrequirements/base-ft.txt21frozenlist==1.8.0
LOWrequirements/base-ft.txt41pycparser==3.0
LOWrequirements/multidict.txt1#
LOWrequirements/constraints.txt1#
LOWrequirements/constraints.txt21 # -r requirements/runtime-deps.in
LOWrequirements/constraints.txt41 # via
LOWrequirements/constraints.txt61 # via requests
LOWrequirements/constraints.txt81 # sphinx
LOWrequirements/constraints.txt101gunicorn==26.0.0
LOWrequirements/constraints.txt121 # sphinx
LOWrequirements/constraints.txt141 # aiohttp
LOWrequirements/constraints.txt161 # via mypy
LOWrequirements/constraints.txt181proxy-py==2.4.10
LOWrequirements/constraints.txt201 # via
LOWrequirements/constraints.txt221pytest-codspeed==5.0.3
LOWrequirements/constraints.txt241 # -r requirements/lint.in
LOWrequirements/constraints.txt261 # via sphinx
LOWrequirements/constraints.txt281sphinxcontrib-serializinghtml==2.0.0
LOWrequirements/constraints.txt301trustme==1.2.1 ; platform_machine != "i686"
LOWrequirements/constraints.txt321urllib3==2.7.0
LOWrequirements/constraints.txt341 # -r requirements/lint.in
LOWrequirements/dev.txt1#
LOWrequirements/dev.txt21 # -r requirements/runtime-deps.in
LOWrequirements/dev.txt41 # via
LOWrequirements/dev.txt61 # via requests
LOWrequirements/dev.txt81 # via pytest
LOWrequirements/dev.txt101identify==2.6.19
LOWrequirements/dev.txt121 # towncrier
LOWrequirements/dev.txt141 # via
LOWrequirements/dev.txt161pkgconfig==1.6.0
LOWrequirements/dev.txt181 # -r requirements/test-common-base.in
LOWrequirements/dev.txt201 # -r requirements/lint.in
LOWrequirements/dev.txt221 # via -r requirements/test-common-base.in
LOWrequirements/dev.txt241 # pre-commit
LOWrequirements/dev.txt261sphinxcontrib-applehelp==2.0.0
LOWrequirements/dev.txt281 # mypy
LOWrequirements/dev.txt301 # multidict
LOWrequirements/dev.txt321wait-for-it==2.3.0
LOWrequirements/cython.txt1#
LOWrequirements/runtime-deps.txt1#
LOWrequirements/runtime-deps.txt21frozenlist==1.8.0
LOWrequirements/runtime-deps.txt41 # -r requirements/runtime-deps.in
LOWrequirements/test-common-base.txt1#
LOWrequirements/test-common-base.txt21exceptiongroup==1.3.1
LOWrequirements/test-common-base.txt41pluggy==1.6.0
LOWrequirements/test-common-base.txt61pytest-aiohttp==1.1.0
LOWrequirements/test-common-base.txt81typing-extensions==4.15.0
LOWrequirements/doc.txt1#
LOWrequirements/doc.txt21 # myst-parser
LOWrequirements/doc.txt41mdurl==0.1.2
62 more matches not shown…
Deep Nesting70 hits · 66 pts
SeverityFileLineSnippet
LOWaiohttp/web_ws.py596
LOWaiohttp/worker.py63
LOWaiohttp/multipart.py77
LOWaiohttp/multipart.py180
LOWaiohttp/web_response.py260
LOWaiohttp/web_response.py296
LOWaiohttp/web_response.py370
LOWaiohttp/web_response.py539
LOWaiohttp/web_response.py609
LOWaiohttp/web_response.py697
LOWaiohttp/client_ws.py384
LOWaiohttp/web_exceptions.py499
LOWaiohttp/web.py279
LOWaiohttp/web.py426
LOWaiohttp/web_protocol.py439
LOWaiohttp/web_protocol.py581
LOWaiohttp/client.py466
LOWaiohttp/client.py1015
LOWaiohttp/web_request.py293
LOWaiohttp/web_request.py615
LOWaiohttp/web_request.py677
LOWaiohttp/client_proto.py115
LOWaiohttp/web_runner.py273
LOWaiohttp/payload.py122
LOWaiohttp/payload.py1015
LOWaiohttp/formdata.py83
LOWaiohttp/connector.py380
LOWaiohttp/connector.py457
LOWaiohttp/connector.py636
LOWaiohttp/connector.py678
LOWaiohttp/connector.py1318
LOWaiohttp/connector.py1425
LOWaiohttp/connector.py1499
LOWaiohttp/web_fileresponse.py288
LOWaiohttp/_cookie_helpers.py167
LOWaiohttp/_cookie_helpers.py266
LOWaiohttp/helpers.py257
LOWaiohttp/helpers.py409
LOWaiohttp/http_parser.py167
LOWaiohttp/http_parser.py319
LOWaiohttp/http_parser.py616
LOWaiohttp/http_parser.py738
LOWaiohttp/http_parser.py802
LOWaiohttp/http_parser.py885
LOWaiohttp/cookiejar.py129
LOWaiohttp/cookiejar.py175
LOWaiohttp/cookiejar.py305
LOWaiohttp/_websocket/helpers.py78
LOWaiohttp/_websocket/reader_py.py194
LOWaiohttp/_websocket/reader_py.py345
LOWaiohttp/_websocket/reader_c.py194
LOWaiohttp/_websocket/reader_c.py345
LOWtests/test_client_session.py585
LOWtests/test_client_middleware.py285
LOWtests/test_client_middleware.py319
LOWtests/test_client_ws.py485
LOWtests/test_client_ws.py519
LOWtests/test_client_ws.py551
LOWtests/test_proxy.py228
LOWtests/test_proxy.py314
10 more matches not shown…
Cross-File Repetition11 hits · 55 pts
SeverityFileLineSnippet
HIGHaiohttp/web_urldispatcher.py0return a dict with additional info useful for introspection
HIGHaiohttp/web_urldispatcher.py0return a dict with additional info useful for introspection
HIGHaiohttp/web_urldispatcher.py0return a dict with additional info useful for introspection
HIGHaiohttp/abc.py0return a dict with additional info useful for introspection
HIGHtests/test_client_middleware.py0test that middleware can update request body using update_body method.
HIGHtests/test_client_middleware.py0test that middleware can update request body using update_body method.
HIGHtests/test_client_middleware.py0test that middleware can update request body using update_body method.
HIGHtests/test_client_middleware.py0test that middleware can update request body using update_body method.
HIGHexamples/web_srv.py0\ type {url}/hello/john {url}/simple or {url}/change_body in browser url bar
HIGHexamples/web_srv_route_table.py0\ type {url}/hello/john {url}/simple or {url}/change_body in browser url bar
HIGHexamples/web_srv_route_deco.py0\ type {url}/hello/john {url}/simple or {url}/change_body in browser url bar
Cross-Language Confusion7 hits · 42 pts
SeverityFileLineSnippet
HIGHaiohttp/helpers.py891 self._name = module + "." + name # type: ignore[possibly-undefined]
HIGHtests/test_benchmarks_web_fileresponse.py137 return resp # type: ignore[possibly-undefined]
HIGHtests/test_client_functional.py5401 "av-profile=null; Domain=.amazon.it; "
HIGHtests/test_benchmarks_http_websocket.py54 b'8","result":{"name":null,"id":"shellyplugus-c049ef8c30e4","mac":"C049EF8C30E'
HIGHtests/test_benchmarks_http_websocket.py56 b'4b5d4f","ver":"1.1.0","app":"PlugUS","auth_en":false,"auth_domain":null}}'
HIGHdocs/code/client_middleware_cookbook.py32 return resp # type: ignore[possibly-undefined]
HIGHdocs/code/client_middleware_cookbook.py69 return resp # type: ignore[possibly-undefined]
Excessive Try-Catch Wrapping27 hits · 28 pts
SeverityFileLineSnippet
LOWaiohttp/web_ws.py530 except Exception as exc:
LOWaiohttp/web_ws.py560 except Exception as exc:
LOWaiohttp/web_ws.py641 except Exception as exc:
LOWaiohttp/worker.py56 except Exception:
LOWaiohttp/worker.py125 except Exception:
LOWaiohttp/multipart.py1171 except Exception as exc:
LOWaiohttp/client_ws.py340 except Exception as exc:
LOWaiohttp/client_ws.py358 except Exception as exc:
LOWaiohttp/client_ws.py431 except Exception as exc:
LOWaiohttp/streams.py208 except Exception:
LOWaiohttp/streams.py232 except Exception:
LOWaiohttp/streams.py582 except Exception:
MEDIUMaiohttp/streams.py44def __anext__(self) -> _T:
LOWaiohttp/web_protocol.py569 except Exception as exc:
LOWaiohttp/web_protocol.py691 except Exception as exc:
LOWaiohttp/client_proto.py150 except Exception as underlying_exc:
LOWaiohttp/client_proto.py326 except Exception as underlying_exc:
LOWaiohttp/client_reqrep.py1411 except Exception as underlying_exc:
LOWaiohttp/web_log.py223 except Exception:
LOWaiohttp/formdata.py142 except Exception as exc:
LOWaiohttp/http_parser.py508 except Exception as underlying_exc:
LOWaiohttp/http_parser.py1129 except Exception:
LOWaiohttp/_websocket/reader_py.py187 except Exception as exc:
LOWaiohttp/_websocket/reader_c.py187 except Exception as exc:
LOWtests/test_client_session.py1224 except Exception:
LOWtests/test_web_exceptions.py166 except Exception as exc:
MEDIUMexamples/client_ws.py31 print("Error during receive %s" % ws.exception())
Redundant / Tautological Comments17 hits · 27 pts
SeverityFileLineSnippet
LOWaiohttp/payload.py624 # Check if we're done writing
LOWaiohttp/connector.py1284 # Check if uvloop is being used, which supports TLS in TLS,
LOWaiohttp/client_middleware_digest_auth.py376 # Check if request starts with space URL
LOWaiohttp/client_middleware_digest_auth.py467 # Check if we need to authenticate
LOWaiohttp/cookiejar.py280 # Check if the cookie hasn't been re-added to the heap
LOWtests/test_client_middleware.py406 # Check if token needs refresh
LOWtests/test_payload.py1268 # Write file in executor
LOWtests/test_payload.py1272 # Open file in executor
LOWtests/test_payload.py1333 # Open the file and create payload
LOWtests/test_payload.py1341 # Read the file (simulating first request)
LOWtests/test_payload.py1292 # Write file in executor
LOWtests/test_payload.py1300 # Open file in executor
LOWexamples/token_refresh_middleware.py53 # Check if another coroutine already refreshed the token
LOWexamples/token_refresh_middleware.py203 # Check if token exists and is not expired
LOWexamples/basic_auth_middleware.py68 # Check if Authorization header is present
LOWexamples/combined_middleware.py140 # Check if we should retry
LOWexamples/retry_middleware.py69 # Check if we should retry
Dead Code4 hits · 8 pts
SeverityFileLineSnippet
MEDIUMtests/test_web_app.py340
MEDIUMtests/test_client_request.py1903
MEDIUMtests/test_run_app.py135
MEDIUMtests/test_run_app.py1032
Verbosity Indicators3 hits · 7 pts
SeverityFileLineSnippet
LOWtests/test_client_middleware.py299 # Step 0: No auth, request client ID
LOWtests/test_client_middleware.py306 # Step 1: Has session, request credentials
LOWtests/test_client_middleware.py313 # Step 2: Has challenge response, authenticate
AI Slop Vocabulary3 hits · 6 pts
SeverityFileLineSnippet
LOWaiohttp/compression_utils.py133 # Everything not explicitly listed in the Protocol we just pass through
MEDIUMtests/test_connector.py2815 """Delay resolve() task in order to test cancellation."""
MEDIUMtests/test_client_ws_functional.py1400 # The test harness will cleanup the unclosed websocket
Docstring Block Structure1 hit · 5 pts
SeverityFileLineSnippet
HIGHaiohttp/client_middleware_digest_auth.py203 Build digest authorization header for the current challenge. Args: method: The HTTP method
Slop Phrases2 hits · 4 pts
SeverityFileLineSnippet
MEDIUMdocs/code/client_middleware_cookbook.py124 # WARNING: This is a simplified example for demonstration purposes only.
MEDIUMexamples/token_refresh_middleware.py13Note: This is a simplified example for demonstration purposes.
Decorative Section Separators1 hit · 3 pts
SeverityFileLineSnippet
MEDIUMdocs/conf.py410# -------------------------------------------------------------------------
Fake / Example Data1 hit · 1 pts
SeverityFileLineSnippet
LOWexamples/fake_server.py73 return web.json_response({"name": "John Doe", "id": "12345678901234567"})