Repository Analysis

benoitc/gunicorn

gunicorn 'Green Unicorn' is a WSGI HTTP Server for UNIX, fast clients and sleepy applications.

48.5 Strong AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of benoitc/gunicorn, a Python project with 10,664 GitHub stars. SynthScan v2.0 examined 102,405 lines of code across 567 source files, recording 2954 pattern matches distributed across 22 syntactic categories. The overall adjusted score of 48.5 places this repository in the Strong 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).

48.5
Adjusted Score
48.5
Raw Score
100%
Time Factor
2026-08-29
Last Push
10.7K
Stars
Python
Language
102.4K
Lines of Code
567
Files
3.0K
Pattern Hits
2026-08-29
Scan Date
0.05
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

Longitudinal tracking requires multiple scan runs. Once this repository is re-scanned after new commits land, this chart will visualise how the synthetic code signal evolves over time — enabling you to detect whether AI authorship is growing, stabilising, or being actively corrected by human engineers.

No multi-scan history yet — run the scanner again to build trend data.

Severity Breakdown

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.

CRITICAL 0HIGH 31MEDIUM 931LOW 1992

Directory Score Breakdown

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.

Pattern Findings

The scanner identified 2954 distinct pattern matches across 22 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.

Self-Referential Comments486 hits · 1468 pts
SeverityFileLineSnippetContext
MEDIUMtests/test_gtornado.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_gtornado.py331 # Create a mock handler to test the patched clear methodCOMMENT
MEDIUMtests/support_dirty_apps.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_invalid_requests.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_header_security.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_alpn.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_python_protocol.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/conftest.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_error_handling.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_error_handling.py242 # Create a mock taskCOMMENT
MEDIUMtests/test_asgi_error_handling.py261 # Create a mock task that's already doneCOMMENT
MEDIUMtests/test_dirty_errors.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_http_scope.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/support.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_worker.py391 # Create a minimal protocol instanceCOMMENT
MEDIUMtests/test_asgi_worker.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_errors.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_debug.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_request.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_request.py697 # Create a mock socketCOMMENT
MEDIUMtests/test_http2_request.py716 # Create a mock HTTP/1 request (no priority attributes)COMMENT
MEDIUMtests/test_asgi_forwarded_headers.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_statsd.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_pidfile.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_streaming.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_disconnect.py61 # Create a mock request for the body receiverCOMMENT
MEDIUMtests/test_asgi_disconnect.py66 # Create a body receiver (simulating active request)COMMENT
MEDIUMtests/test_asgi_disconnect.py173 # Create a mock task that's still runningCOMMENT
MEDIUMtests/test_asgi_disconnect.py186 # Create a mock task that's already doneCOMMENT
MEDIUMtests/test_asgi_disconnect.py203 # Create a mock request with no bodyCOMMENT
MEDIUMtests/test_asgi_disconnect.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_disconnect.py87 # Create a mock request for the body receiverCOMMENT
MEDIUMtests/test_asgi_disconnect.py134 # Create a mock taskCOMMENT
MEDIUMtests/test_asgi_disconnect.py155 # Create a mock taskCOMMENT
MEDIUMtests/test_asgi_websocket_enhanced.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_arbiter.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_systemd.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_tlv.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_util.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_parser_validation.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_integration.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_app.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_proxy_protocol.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_keepalive_smuggling.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/treq_asgi.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_integration.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_header_policy_parity.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_arbiter.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_hooks.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http2_stream.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_signal_integration.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_http2_response.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/treq.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/treq.py7# This file is part of the pywebmachine package releasedCOMMENT
MEDIUMtests/test_ssl.py3# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_http.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_sock.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_dirty_protocol.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_asgi_invalid_requests.py2# This file is part of gunicorn released under the MIT license.COMMENT
MEDIUMtests/test_valid_requests.py2# This file is part of gunicorn released under the MIT license.COMMENT
426 more matches not shown…
Decorative Section Separators424 hits · 1447 pts
SeverityFileLineSnippetContext
MEDIUMtests/test_asgi_header_security.py21# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py23# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py91# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py93# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py246# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py248# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py296# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py298# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py340# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py342# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py152# ============================================================================COMMENT
MEDIUMtests/test_asgi_header_security.py154# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py88# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py90# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py316# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py318# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py353# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py355# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py20# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py22# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py120# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py122# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py216# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py218# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py274# ============================================================================COMMENT
MEDIUMtests/test_asgi_error_handling.py276# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py96# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py98# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py18# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py20# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py178# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py180# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py256# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py258# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py350# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py352# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py478# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py480# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py564# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py566# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py647# ============================================================================COMMENT
MEDIUMtests/test_asgi_http_scope.py649# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py270# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py272# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py671# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py673# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py24# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py26# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py112# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py114# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py125# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py127# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py349# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py351# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py412# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py414# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py527# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py529# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py726# ============================================================================COMMENT
MEDIUMtests/test_asgi_worker.py728# ============================================================================COMMENT
364 more matches not shown…
Hyper-Verbose Identifiers1427 hits · 1261 pts
SeverityFileLineSnippetContext
LOWtests/test_gtornado.py77 def test_init_process_clears_ioloop(self):CODE
LOWtests/test_gtornado.py109 def test_handle_request_increments_counter(self):CODE
LOWtests/test_gtornado.py121 def test_max_requests_triggers_shutdown(self):CODE
LOWtests/test_gtornado.py155 def test_handle_exit_sets_alive_false(self):CODE
LOWtests/test_gtornado.py165 def test_handle_exit_only_once(self):CODE
LOWtests/test_gtornado.py200 def test_watchdog_notifies_when_alive(self):CODE
LOWtests/test_gtornado.py211 def test_watchdog_detects_parent_death(self):CODE
LOWtests/test_gtornado.py242 def test_heartbeat_stops_server_when_not_alive(self):CODE
LOWtests/test_gtornado.py254 def test_heartbeat_stops_ioloop_after_server(self):CODE
LOWtests/test_gtornado.py288 def test_wsgi_callable_wrapped_in_container(self):CODE
LOWtests/test_gtornado.py303 def test_tornado_application_not_wrapped(self):CODE
LOWtests/test_gtornado.py323 def test_setup_patches_request_handler(self):CODE
LOWtests/test_gtornado.py364 def test_run_sets_up_callbacks(self):CODE
LOWtests/test_gtornado.py384 def test_run_creates_http_server(self):CODE
LOWtests/test_gtornado.py400 def test_run_adds_sockets_to_server(self):CODE
LOWtests/test_asgi_header_security.py28 def test_valid_header_name_accepted(self):CODE
LOWtests/test_asgi_header_security.py98 def test_header_value_with_bare_cr_rejected(self):CODE
LOWtests/test_asgi_header_security.py253 def test_oversized_header_value_handled(self):CODE
LOWtests/test_asgi_header_security.py303 def test_valid_host_header_accepted(self):CODE
LOWtests/test_asgi_header_security.py347 def test_content_type_with_charset(self):CODE
LOWtests/test_asgi_header_security.py42 def test_header_name_with_null_rejected(self):CODE
LOWtests/test_asgi_header_security.py54 def test_header_name_with_cr_rejected(self):CODE
LOWtests/test_asgi_header_security.py66 def test_header_name_with_lf_rejected(self):CODE
LOWtests/test_asgi_header_security.py78 def test_empty_header_name_rejected(self):CODE
LOWtests/test_asgi_header_security.py111 def test_header_value_with_bare_lf_rejected(self):CODE
LOWtests/test_asgi_header_security.py124 def test_header_value_special_characters_allowed(self):CODE
LOWtests/test_asgi_header_security.py138 def test_header_value_with_tab_allowed(self):CODE
LOWtests/test_asgi_header_security.py186 def test_headers_lowercased_in_scope(self):CODE
LOWtests/test_asgi_header_security.py201 def test_header_names_are_bytes(self):CODE
LOWtests/test_asgi_header_security.py215 def test_header_values_are_bytes(self):CODE
LOWtests/test_asgi_header_security.py229 def test_header_order_preserved(self):CODE
LOWtests/test_asgi_header_security.py273 def test_many_headers_handled(self):CODE
LOWtests/test_asgi_header_security.py315 def test_host_header_with_port_accepted(self):CODE
LOWtests/test_asgi_header_security.py361 def test_content_type_multipart(self):CODE
LOWtests/test_http2_alpn.py52 def test_empty_protocols_returns_empty(self):CODE
LOWtests/test_http2_alpn.py59 def test_none_protocols_returns_empty(self):CODE
LOWtests/test_http2_alpn.py79 def test_returns_alpn_protocol(self):CODE
LOWtests/test_http2_alpn.py89 def test_returns_none_when_not_negotiated(self):CODE
LOWtests/test_http2_alpn.py94 def test_returns_none_for_non_ssl_socket(self):CODE
LOWtests/test_http2_alpn.py99 def test_handles_attribute_error(self):CODE
LOWtests/test_http2_alpn.py127 def test_returns_false_for_none(self):CODE
LOWtests/test_http2_alpn.py132 def test_returns_false_for_non_ssl(self):CODE
LOWtests/test_http2_alpn.py236 def test_handshake_called_when_do_handshake_on_connect_false(self, async_worker):CODE
LOWtests/test_http2_alpn.py254 def test_no_handshake_when_do_handshake_on_connect_true(self, async_worker):CODE
LOWtests/test_http2_alpn.py273 def test_no_handshake_for_non_ssl_socket(self, async_worker):CODE
LOWtests/test_http2_alpn.py333 def test_gevent_inherits_async_worker(self):CODE
LOWtests/test_http2_alpn.py345 def test_gevent_handle_calls_super(self, gevent_worker):CODE
LOWtests/test_python_protocol.py38 def test_get_with_query_string(self):CODE
LOWtests/test_python_protocol.py94 def test_post_with_content_length(self):CODE
LOWtests/test_python_protocol.py139 def test_chunked_with_extension(self):CODE
LOWtests/test_python_protocol.py163 def test_partial_request_line(self):CODE
LOWtests/test_python_protocol.py210 def test_partial_chunked_body(self):CODE
LOWtests/test_python_protocol.py235 def test_invalid_request_line(self):CODE
LOWtests/test_python_protocol.py249 def test_unsupported_http_version(self):CODE
LOWtests/test_python_protocol.py290 def test_multiple_requests_keepalive(self):CODE
LOWtests/test_python_protocol.py407 def test_from_parser_body_info(self):CODE
LOWtests/test_python_protocol.py492 def test_connection_close_header(self):CODE
LOWtests/test_python_protocol.py499 def test_connection_keepalive_header(self):CODE
LOWtests/test_asgi_error_handling.py95 def test_response_info_initial(self):CODE
LOWtests/test_asgi_error_handling.py105 def test_response_info_with_headers(self):CODE
1367 more matches not shown…
Excessive Try-Catch Wrapping185 hits · 211 pts
SeverityFileLineSnippetContext
LOWtests/test_http2_alpn.py171 except Exception:CODE
MEDIUMtests/test_dirty_arbiter.py370def mock_consumer():CODE
LOWtests/test_dirty_arbiter.py765 except Exception:CODE
LOWtests/test_dirty_integration.py242 except Exception:CODE
LOWtests/test_arbiter.py297 except Exception:CODE
LOWtests/test_asgi_invalid_requests.py119 except Exception as exc: # parser rejected it outright, also fineCODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py110 except Exception as e:CODE
MEDIUM…/asgi_framework_compat/frameworks/starlette_app/app.py111 print(f"Error serializing key {key}: {e}", file=sys.stderr)CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py127 except Exception as e:CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py210 except Exception:CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py221 except Exception:CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py231 except Exception as e:CODE
LOW…er/asgi_framework_compat/frameworks/fastapi_app/app.py106 except Exception as e:CODE
MEDIUM…er/asgi_framework_compat/frameworks/fastapi_app/app.py107 print(f"Error serializing key {key}: {e}", file=sys.stderr)CODE
LOW…er/asgi_framework_compat/frameworks/fastapi_app/app.py125 except Exception as e:CODE
LOW…er/asgi_framework_compat/frameworks/fastapi_app/app.py238 except Exception as e:CODE
LOW…r/asgi_framework_compat/frameworks/litestar_app/app.py184 except Exception:CODE
LOW…r/asgi_framework_compat/frameworks/litestar_app/app.py196 except Exception:CODE
LOW…asgi_framework_compat/frameworks/blacksheep_app/app.py182 except Exception:CODE
LOW…asgi_framework_compat/frameworks/blacksheep_app/app.py194 except Exception:CODE
LOWtests/docker/per_app_allocation/app.py83 except Exception as e:CODE
LOW…s/docker/asgi_compliance/test_framework_integration.py161 except Exception as e:CODE
LOW…s/docker/asgi_compliance/test_framework_integration.py324 except Exception as e:CODE
LOW…s/docker/asgi_compliance/test_framework_integration.py139 except Exception:CODE
LOW…s/docker/asgi_compliance/test_framework_integration.py302 except Exception:CODE
LOWtests/docker/asgi_compliance/apps/framework_apps.py150 except Exception:CODE
LOWtests/docker/asgi_compliance/apps/framework_apps.py293 except Exception:CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py335 except Exception:CODE
LOWtests/docker/dirty_ttin_ttou/app.py58 except Exception as e:CODE
LOWtests/docker/dirty_ttin_ttou/app.py69 except Exception as e:CODE
LOWgunicorn/pidfile.py61 except Exception:CODE
LOWgunicorn/util.py103 except Exception:CODE
LOWgunicorn/util.py122 except Exception:CODE
LOWgunicorn/util.py131 except Exception:CODE
LOWgunicorn/util.py504 except Exception:CODE
MEDIUMgunicorn/util.py223def unlink(filename):CODE
LOWgunicorn/systemd.py71 except Exception:CODE
MEDIUMgunicorn/arbiter.py133 print("Error: restoring the previous logger "CODE
LOWgunicorn/arbiter.py121 except Exception:CODE
LOWgunicorn/arbiter.py132 except Exception:CODE
LOWgunicorn/arbiter.py282 except Exception:CODE
LOWgunicorn/arbiter.py484 except Exception:CODE
LOWgunicorn/arbiter.py763 except Exception as e:CODE
LOWgunicorn/arbiter.py775 except Exception:CODE
LOWgunicorn/arbiter.py920 except Exception:CODE
LOWgunicorn/arbiter.py1024 except Exception as e:CODE
LOWgunicorn/arbiter.py1035 except Exception as e:CODE
LOWgunicorn/glogging.py383 except Exception:CODE
LOWgunicorn/asgi/protocol.py1714 except Exception as e:CODE
LOWgunicorn/asgi/protocol.py1720 except Exception:CODE
LOWgunicorn/asgi/protocol.py1728 except Exception as e:CODE
LOWgunicorn/asgi/protocol.py1732 except Exception:CODE
LOWgunicorn/asgi/protocol.py746 except Exception as e:CODE
LOWgunicorn/asgi/protocol.py1010 except Exception as e:CODE
LOWgunicorn/asgi/protocol.py1273 except Exception:CODE
LOWgunicorn/asgi/protocol.py1301 except Exception:CODE
LOWgunicorn/asgi/protocol.py1647 except Exception:CODE
LOWgunicorn/asgi/protocol.py1695 except Exception as e:CODE
LOWgunicorn/asgi/protocol.py1927 except Exception:CODE
LOWgunicorn/asgi/protocol.py1946 except Exception:CODE
125 more matches not shown…
Deep Nesting149 hits · 143 pts
SeverityFileLineSnippetContext
LOWtests/test_gtornado.py440CODE
LOWtests/test_asgi_worker.py74CODE
LOWtests/test_dirty_integration.py194CODE
LOWtests/test_dirty_integration.py285CODE
LOWtests/docker/asgi/app.py8CODE
LOWtests/docker/asgi_framework_compat/conftest.py57CODE
LOW…/docker/asgi_framework_compat/scripts/generate_grid.py79CODE
LOW…er/asgi_framework_compat/frameworks/django_app/asgi.py32CODE
LOW…gi_framework_compat/frameworks/django_app/consumers.py9CODE
LOW…r/asgi_framework_compat/frameworks/django_app/views.py17CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py46CODE
LOW…/asgi_framework_compat/frameworks/starlette_app/app.py66CODE
LOW…er/asgi_framework_compat/frameworks/fastapi_app/app.py42CODE
LOW…er/asgi_framework_compat/frameworks/fastapi_app/app.py62CODE
LOW…r/asgi_framework_compat/frameworks/litestar_app/app.py40CODE
LOW…asgi_framework_compat/frameworks/blacksheep_app/app.py42CODE
LOW…cker/asgi_framework_compat/frameworks/quart_app/app.py40CODE
LOWtests/docker/dirty_arbiter/test_parent_death.py132CODE
LOWtests/docker/dirty_arbiter/test_parent_death.py500CODE
LOWtests/docker/per_app_allocation/test_per_app_e2e.py101CODE
LOWtests/docker/per_app_allocation/test_per_app_e2e.py137CODE
LOWtests/docker/per_app_allocation/app.py21CODE
LOWtests/docker/http2/conftest.py49CODE
LOWtests/docker/http2/app.py10CODE
LOWtests/docker/test_asgi_uwsgi/app.py8CODE
LOWtests/docker/uwsgi/app.py15CODE
LOWtests/docker/asgi_compliance/conftest.py62CODE
LOWtests/docker/asgi_compliance/conftest.py290CODE
LOWtests/docker/asgi_compliance/conftest.py308CODE
LOW…ts/docker/asgi_compliance/test_streaming_compliance.py93CODE
LOWtests/docker/asgi_compliance/apps/lifespan_app.py28CODE
LOWtests/docker/asgi_compliance/apps/lifespan_app.py53CODE
LOWtests/docker/asgi_compliance/apps/websocket_app.py15CODE
LOWtests/docker/asgi_compliance/apps/websocket_app.py68CODE
LOWtests/docker/asgi_compliance/apps/websocket_app.py100CODE
LOWtests/docker/asgi_compliance/apps/websocket_app.py259CODE
LOWtests/docker/asgi_compliance/apps/websocket_app.py377CODE
LOWtests/docker/asgi_compliance/apps/framework_apps.py47CODE
LOWtests/docker/asgi_compliance/apps/framework_apps.py304CODE
LOWtests/docker/asgi_compliance/apps/http_app.py16CODE
LOWtests/docker/asgi_compliance/apps/http_app.py309CODE
LOWtests/docker/asgi_compliance/apps/http_app.py489CODE
LOWtests/docker/asgi_compliance/apps/http_app.py537CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py17CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py106CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py205CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py249CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py293CODE
LOWtests/docker/asgi_compliance/apps/streaming_app.py380CODE
LOWtests/docker/asgi_compliance/apps/main_app.py29CODE
LOWtests/docker/asgi_compliance/apps/main_app.py98CODE
LOWtests/docker/dirty_ttin_ttou/test_ttin_ttou_docker.py106CODE
LOWtests/ctl/test_server.py328CODE
LOWgunicorn/pidfile.py64CODE
LOWgunicorn/reloader.py54CODE
LOWgunicorn/util.py88CODE
LOWgunicorn/util.py521CODE
LOWgunicorn/sock.py165CODE
LOWgunicorn/debug.py24CODE
LOWgunicorn/arbiter.py166CODE
89 more matches not shown…
Docstring Block Structure26 hits · 130 pts
SeverityFileLineSnippetContext
HIGHgunicorn/asgi/uwsgi.py66Parse a uWSGI request asynchronously. Args: cfg: gunicorn config object unreader: AsyncSTRING
HIGHgunicorn/http2/async_connection.py174Receive data and return completed requests. Args: timeout: Optional timeout in seconds for read opeSTRING
HIGHgunicorn/http2/async_connection.py545Send trailing headers on a stream. Trailers are headers sent after the response body, commonly used forSTRING
HIGHgunicorn/http2/connection.py179Process received data and return completed requests. Args: data: Optional bytes to process. If NoneSTRING
HIGHgunicorn/http2/connection.py501Send a response on a stream. Args: stream_id: The stream ID to respond on status: HTTP STRING
HIGHgunicorn/http2/connection.py640Send trailing headers on a stream. Trailers are headers sent after the response body, commonly used forSTRING
HIGHgunicorn/dirty/worker.py451 Execute an action on a dirty app. The action runs in a thread pool executor to avoid blocking the STRING
HIGHgunicorn/dirty/protocol.py132 Decode the 16-byte message header. Args: data: 16 bytes of header data Returns: STRING
HIGHgunicorn/dirty/protocol.py360 Decode a complete message (header + payload). Args: data: Complete message bytes STRING
HIGHgunicorn/dirty/protocol.py409 Read a complete binary message from async stream. Args: reader: asyncio StreamReader STRING
HIGHgunicorn/dirty/protocol.py493 Receive exactly n bytes from a socket. Args: sock: Socket to read from n: NumbSTRING
HIGHgunicorn/dirty/protocol.py521 Read a complete message from socket (sync). Args: sock: Socket to read from ReturSTRING
HIGHgunicorn/dirty/client.py81 Execute an action on a dirty app (sync/blocking). Args: app_path: Import path of the dirtySTRING
HIGHgunicorn/dirty/client.py139 Stream results from a dirty app action (sync). This method returns an iterator that yields chunks fromSTRING
HIGHgunicorn/dirty/client.py224 Execute an action on a dirty app (async/non-blocking). Args: app_path: Import path of the STRING
HIGHgunicorn/dirty/client.py280 Stream results from a dirty app action (async). This method returns an async iterator that yields chunSTRING
HIGHgunicorn/dirty/tlv.py54 Encode a Python value to TLV binary format. Args: value: Python value to encode (None, booSTRING
HIGHgunicorn/dirty/tlv.py129 Decode a TLV-encoded value from binary data. Args: data: Binary data to decode STRING
HIGHgunicorn/dirty/tlv.py285 Decode a complete TLV-encoded value, ensuring all data is consumed. Args: data: Binary datSTRING
HIGHgunicorn/dirty/app.py111 Handle a request from an HTTP worker. Args: action: The action/method name to execute STRING
HIGHgunicorn/dirty/app.py141 Parse a dirty app specification. Supports two formats: - ``"module:Class"`` - standard format, all workersSTRING
HIGHgunicorn/dirty/app.py216 Load a dirty app class from an import path. Args: import_path: String in format 'module.path:ClassNameSTRING
HIGHgunicorn/dirty/app.py282 Load multiple dirty apps from a list of import paths. Args: import_paths: List of import path strings STRING
HIGHgunicorn/dirty/app.py301 Get the workers class attribute from a dirty app without instantiating it. This is used by the arbiter to deteSTRING
HIGHgunicorn/ctl/protocol.py79 Read one message from a socket. Args: sock: Socket to read from Returns: STRING
HIGHgunicorn/ctl/client.py75 Send command and wait for response. Args: command: Command string (e.g., "show workers") STRING
Unused Imports112 hits · 102 pts
SeverityFileLineSnippetContext
LOWtests/test_http2_alpn.py312CODE
LOWtests/test_http2_alpn.py336CODE
LOWtests/test_dirty_errors.py7CODE
LOWtests/test_asgi_forwarded_headers.py14CODE
LOWtests/test_asgi_streaming.py14CODE
LOWtests/test_dirty_arbiter.py10CODE
LOWtests/test_dirty_tlv.py11CODE
LOWtests/test_dirty_tlv.py11CODE
LOWtests/test_dirty_tlv.py11CODE
LOWtests/test_asgi_parser_validation.py13CODE
LOWtests/test_dirty_integration.py8CODE
LOWtests/test_uwsgi.py5CODE
LOWtests/test_uwsgi.py7CODE
LOWtests/test_uwsgi.py9CODE
LOWtests/test_http2_connection.py935CODE
LOWtests/test_http2_connection.py974CODE
LOWtests/test_http2_h2c.py26CODE
LOWtests/test_asgi_protocol_http.py14CODE
LOWtests/test_asgi_protocol_http.py17CODE
LOWtests/test_asgi_protocol_http.py17CODE
LOWtests/test_dirty_stash.py7CODE
LOWtests/test_dirty_stash.py9CODE
LOWtests/test_control_socket_integration.py17CODE
LOWtests/test_control_socket_integration.py225CODE
LOWtests/test_http2_async_connection.py947CODE
LOWtests/test_http2_async_connection.py988CODE
LOWtests/test_dirty_worker.py15CODE
LOWtests/test_dirty_worker.py25CODE
LOWtests/docker/asgi_framework_compat/conftest.py8CODE
LOWtests/docker/asgi_framework_compat/conftest.py9CODE
LOW…s/docker/asgi_framework_compat/tests/test_streaming.py7CODE
LOW…er/asgi_framework_compat/tests/test_websocket_scope.py11CODE
LOW…er/asgi_framework_compat/tests/test_websocket_scope.py14CODE
LOW…/docker/asgi_framework_compat/scripts/generate_grid.py10CODE
LOW…asgi_framework_compat/frameworks/blacksheep_app/app.py11CODE
LOW…cker/asgi_framework_compat/frameworks/quart_app/app.py12CODE
LOWtests/docker/dirty_arbiter/test_parent_death.py27CODE
LOWtests/docker/per_app_allocation/test_per_app_e2e.py27CODE
LOWtests/docker/asgi_compliance/test_concurrency.py12CODE
LOWtests/docker/asgi_compliance/apps/framework_apps.py13CODE
LOWtests/docker/dirty_ttin_ttou/test_ttin_ttou_docker.py7CODE
LOWtests/requests/valid/compat_obs_fold.py5CODE
LOWtests/dirty/test_worker_streaming.py8CODE
LOWtests/dirty/test_worker_streaming.py13CODE
LOWtests/dirty/test_worker_streaming.py13CODE
LOWtests/dirty/test_worker_streaming.py13CODE
LOWtests/dirty/test_client_streaming_async.py8CODE
LOWtests/dirty/test_client_streaming_async.py11CODE
LOWtests/dirty/test_arbiter_streaming.py8CODE
LOWtests/dirty/test_client_streaming.py7CODE
LOWtests/dirty/test_client_streaming.py8CODE
LOWtests/dirty/test_client_streaming.py10CODE
LOWtests/dirty/test_client_streaming.py12CODE
LOWtests/dirty/test_client_streaming.py12CODE
LOWtests/dirty/test_client_streaming.py22CODE
LOWtests/dirty/test_multi_app_routing.py13CODE
LOWtests/dirty/test_streaming_integration.py13CODE
LOWtests/dirty/test_streaming_integration.py14CODE
LOWtests/dirty/test_streaming_integration.py19CODE
LOWtests/dirty/test_streaming_integration.py31CODE
52 more matches not shown…
Redundant / Tautological Comments39 hits · 60 pts
SeverityFileLineSnippetContext
LOWtests/test_http2_integration.py13# Check if h2 is availableCOMMENT
LOWtests/test_http2_connection.py14# Check if h2 is available for integration testsCOMMENT
LOWtests/test_http2_h2c.py17# Check if h2 is availableCOMMENT
LOWtests/test_early_hints.py12# Check if h2 is available for HTTP/2 testsCOMMENT
LOWtests/test_http2_async_connection.py15# Check if h2 is available for integration testsCOMMENT
LOWtests/docker/asgi_framework_compat/conftest.py99 # Check if containers are already runningCOMMENT
LOW…ker/asgi_framework_compat/tests/test_lifespan_scope.py47 # Increment onceCOMMENT
LOW…ker/asgi_framework_compat/tests/test_lifespan_scope.py91 # Increment counterCOMMENT
LOWtests/docker/dirty_arbiter/test_parent_death.py198 # Check if it's actually docker-init by checking its childrenCOMMENT
LOWtests/docker/http2/conftest.py92 # Check if Docker is availableCOMMENT
LOWtests/docker/http2/conftest.py102 # Check if docker compose is availableCOMMENT
LOWtests/docker/asgi_compliance/conftest.py99 # Check if Docker is availableCOMMENT
LOWtests/docker/asgi_compliance/conftest.py109 # Check if docker compose is availableCOMMENT
LOWtests/workers/test_gevent_import_order.py61 # Check if concurrent.futures is now importedCOMMENT
LOWtests/workers/test_gevent_import_order.py112 # Check if the lock is a gevent lockCOMMENT
LOWtests/workers/test_gevent_import_order.py172 # Check if the lock is a gevent lockCOMMENT
LOWgunicorn/sock.py254 # Check if h2 library is availableCOMMENT
LOWgunicorn/arbiter.py597 # Check if all remaining workers are newer than last_worker_ageCOMMENT
LOWgunicorn/arbiter.py855 # Check if process existsCOMMENT
LOWgunicorn/asgi/protocol.py412 # Check if HTTP/2 was negotiated via ALPNCOMMENT
LOWgunicorn/asgi/protocol.py1163 # Check if Content-Length or Transfer-Encoding is presentCOMMENT
LOWgunicorn/asgi/protocol.py1775 # Check if stream is closed or missingCOMMENT
LOWgunicorn/asgi/parser.py406 # Check if we have the complete headerCOMMENT
LOWgunicorn/http/message.py503 # Check if fast parser should be usedCOMMENT
LOWgunicorn/dirty/worker.py349 # Check if result is a generator (streaming)COMMENT
LOWgunicorn/dirty/stash.py362 # Check if key actually exists with None valueCOMMENT
LOWgunicorn/dirty/arbiter.py388 # Check if parent (main arbiter) died unexpectedlyCOMMENT
LOWgunicorn/workers/base_async.py45 # Check if HTTP/2 was negotiated (for SSL connections)COMMENT
LOWgunicorn/workers/gasgi.py205 # Check if parent is still aliveCOMMENT
LOWgunicorn/workers/gthread.py613 # Check if we need to closeCOMMENT
LOWgunicorn/workers/gthread.py79 # Check if HTTP/2 was negotiated via ALPNCOMMENT
LOWgunicorn/workers/gthread.py413 # Check if we can accept more connectionsCOMMENT
LOWgunicorn/uwsgi/message.py62 # Check if the source IP is allowedCOMMENT
LOWexamples/http2_gevent/generate_certs.sh17# Check if certificates already existCOMMENT
LOWexamples/http2_gevent/test_http2_gevent.py297 # Check if pytest is availableCOMMENT
LOWexamples/celery_alternative/run_tests.sh24# Check if integration tests should runCOMMENT
LOWbenchmarks/http_parser_benchmark.py23# Check if fast parser is availableCOMMENT
LOWbenchmarks/http_parser_benchmark.py202 # Print resultsCOMMENT
LOWscripts/run_docker_tests.sh18# Set PYTEST to choose the runner, e.g. PYTEST=".venv/bin/python -m pytest".COMMENT
Over-Commented Block49 hits · 49 pts
SeverityFileLineSnippetContext
LOWappveyor.yml1version: '{branch}.{build}'COMMENT
LOWappveyor.yml21 #- TOXENV: py38COMMENT
LOWtests/config/__init__.py1#COMMENT
LOW…sts/invalid/rfc9112_target_authority_non_connect_01.py1#COMMENT
LOW…/requests/invalid/rfc9110_trailer_forbidden_host_01.py1#COMMENT
LOW…sts/requests/invalid/rfc9110_field_value_ctl_del_01.py1#COMMENT
LOW…ts/requests/invalid/rfc9110_trailer_forbidden_cl_01.py1#COMMENT
LOW…ests/invalid/rfc9112_target_asterisk_non_options_01.py1#COMMENT
LOW…ts/requests/invalid/rfc9110_trailer_forbidden_te_01.py1#COMMENT
LOWtests/requests/invalid/rfc9112_target_relative_01.py1#COMMENT
LOW…/requests/invalid/rfc9112_chunked_size_plus_sign_01.py1#COMMENT
LOW…ts/requests/invalid/rfc9112_smuggle_cl_list_form_01.py1#COMMENT
LOW…sts/requests/invalid/rfc9110_field_value_ctl_bel_01.py1#COMMENT
LOW…s/requests/invalid/rfc9112_smuggle_cl_te_chunked_01.py1#COMMENT
LOWtests/workers/__init__.py1#COMMENT
LOWtests/ctl/__init__.py1#COMMENT
LOWgunicorn/util.py561 fd_null = os.open(REDIRECT_TO, os.O_RDWR)COMMENT
LOWgunicorn/util.py581 #COMMENT
LOWgunicorn/app/__init__.py1#COMMENT
LOWgunicorn/instrument/__init__.py1#COMMENT
LOWgunicorn/http/message.py881 if not 3 <= len(bits[0]) <= 20:COMMENT
LOWgunicorn/workers/gthread.py481 # For new connections (not yet initialized), wait for data with timeoutCOMMENT
LOWexamples/alt_spec.py1#COMMENT
LOWexamples/multiapp.py1#COMMENT
LOWexamples/standalone_app.py1#COMMENT
LOWexamples/readline_app.py1#COMMENT
LOWexamples/example_config.py1#COMMENT
LOWexamples/example_config.py21# Must be a positive integer. Generally set in the 64-2048COMMENT
LOWexamples/example_config.py41# https://gunicorn.org/design/#choosing-a-worker-typeCOMMENT
LOWexamples/example_config.py61# higher if you're sure of the repercussions for sync workers.COMMENT
LOWexamples/example_config.py81# nuclear option.COMMENT
LOWexamples/example_config.py101#COMMENT
LOWexamples/example_config.py141# LoggingCOMMENT
LOWexamples/example_config.py161# that Gunicorn processes are reported in the system processCOMMENT
LOWexamples/streaming_chat/__init__.py1#COMMENT
LOWexamples/http2_features/__init__.py1#COMMENT
LOWexamples/http2_gevent/docker-compose.yml1# HTTP/2 with Gevent Docker ComposeCOMMENT
LOWexamples/deep/__init__.py1#COMMENT
LOWexamples/dirty_example/__init__.py1#COMMENT
LOWexamples/embedding_service/__init__.py1#COMMENT
LOWexamples/frameworks/django/testing/testing/__init__.py1#COMMENT
LOWexamples/frameworks/django/testing/testing/settings.py61COMMENT
LOW…les/frameworks/django/testing/testing/apps/__init__.py1#COMMENT
LOW…ameworks/django/testing/testing/apps/someapp/models.py1#COMMENT
LOW…eworks/django/testing/testing/apps/someapp/__init__.py1#COMMENT
LOWexamples/celery_alternative/docker-compose.yml61# - redisCOMMENT
LOWexamples/celery_alternative/tests/__init__.py1#COMMENT
LOWscripts/update_thanks.py1#COMMENT
LOWscripts/run_docker_tests.sh1#!/bin/shCOMMENT
Cross-File Repetition3 hits · 15 pts
SeverityFileLineSnippetContext
HIGHtests/test_http2_integration.py0real gunicorn configuration with the http/2 defaults these tests want. http2request applies the same header policy as htSTRING
HIGHtests/test_http2_connection.py0real gunicorn configuration with the http/2 defaults these tests want. http2request applies the same header policy as htSTRING
HIGHtests/test_http2_async_connection.py0real gunicorn configuration with the http/2 defaults these tests want. http2request applies the same header policy as htSTRING
Modern Structural Boilerplate13 hits · 13 pts
SeverityFileLineSnippetContext
LOWgunicorn/debug.py13__all__ = ['spew', 'unspew']CODE
LOWgunicorn/asgi/__init__.py24__all__ = ['AsyncUnreader', 'LifespanManager']CODE
LOWgunicorn/http2/async_connection.py656__all__ = ['AsyncHTTP2Connection']CODE
LOWgunicorn/http2/request.py267__all__ = ['HTTP2Request', 'HTTP2Body']CODE
LOWgunicorn/http2/__init__.py80__all__ = [CODE
LOWgunicorn/http2/stream.py364__all__ = ['HTTP2Stream', 'StreamState']CODE
LOWgunicorn/http2/connection.py765__all__ = ['HTTP2ServerConnection']CODE
LOWgunicorn/http2/errors.py149__all__ = [CODE
LOWgunicorn/http/__init__.py36__all__ = ['Message', 'Request', 'RequestParser', 'get_parser']CODE
LOWgunicorn/dirty/__init__.py54__all__ = [CODE
LOWgunicorn/uwsgi/__init__.py14__all__ = [CODE
LOWgunicorn/ctl/__init__.py16__all__ = ['ControlSocketServer', 'ControlClient', 'ControlProtocol']CODE
LOWexamples/websocket/gevent_websocket.py19logger = logging.getLogger(__name__)CODE
Verbosity Indicators7 hits · 12 pts
SeverityFileLineSnippetContext
LOWtests/test_asgi_compliance.py1022 # Step 1: App reads the bodyCOMMENT
LOWtests/test_asgi_compliance.py1031 # Step 2: App would send response here (simulated)COMMENT
LOWtests/test_asgi_compliance.py1034 # Step 3: App starts listening for disconnect (like Django does)COMMENT
LOWtests/workers/test_gevent_import_order.py223 # Step 1: User starts gunicorn - gunicorn.arbiter gets importedCOMMENT
LOWtests/workers/test_gevent_import_order.py227 # Step 2: Verify concurrent.futures was NOT imported yetCOMMENT
LOWtests/workers/test_gevent_import_order.py231 # Step 3: Now user's config file runs with monkey.patch_all()COMMENT
LOWtests/workers/test_gevent_import_order.py236 # Step 4: Now import concurrent.futures (after patching)COMMENT
Structural Annotation Overuse7 hits · 12 pts
SeverityFileLineSnippetContext
LOWtests/test_asgi_compliance.py1022 # Step 1: App reads the bodyCOMMENT
LOWtests/test_asgi_compliance.py1031 # Step 2: App would send response here (simulated)COMMENT
LOWtests/test_asgi_compliance.py1034 # Step 3: App starts listening for disconnect (like Django does)COMMENT
LOWtests/workers/test_gevent_import_order.py223 # Step 1: User starts gunicorn - gunicorn.arbiter gets importedCOMMENT
LOWtests/workers/test_gevent_import_order.py227 # Step 2: Verify concurrent.futures was NOT imported yetCOMMENT
LOWtests/workers/test_gevent_import_order.py231 # Step 3: Now user's config file runs with monkey.patch_all()COMMENT
LOWtests/workers/test_gevent_import_order.py236 # Step 4: Now import concurrent.futures (after patching)COMMENT
Cross-Language Confusion2 hits · 10 pts
SeverityFileLineSnippetContext
HIGHexamples/asgi/websocket_app.py191 let ws = null;CODE
HIGHexamples/asgi/websocket_app.py210 ws.onclose = () => { log('Disconnected', 'error'); ws = null; };CODE
Slop Phrases5 hits · 10 pts
SeverityFileLineSnippetContext
LOWgunicorn/errors.py12# we inherit from BaseException here to make sure to not be caughtCOMMENT
MEDIUMgunicorn/instrument/statsd.py112 # you can use those directly if you wantCOMMENT
MEDIUMexamples/streaming_chat/chat_app.py43 "Here's a simple example:\n\n"CODE
LOWexamples/frameworks/django/testing/testing/settings.py76 # Don't forget to use absolute paths, not relative paths.COMMENT
LOWexamples/frameworks/django/testing/testing/settings.py129 # Don't forget to use absolute paths, not relative paths.COMMENT
Overly Generic Function Names7 hits · 8 pts
SeverityFileLineSnippetContext
LOWtests/test_http2_h2c.py380 def handle_request(self, listener_name, req, sock, addr):CODE
LOWgunicorn/dirty/worker.py315 async def handle_request(self, message, writer):CODE
LOWgunicorn/workers/sync.py168 def handle_request(self, listener, req, client, addr):CODE
LOWgunicorn/workers/base_async.py268 def handle_request(self, listener_name, req, sock, addr):CODE
LOWgunicorn/workers/gtornado.py39 def handle_request(self):CODE
LOWgunicorn/workers/ggevent.py122 def handle_request(self, listener_name, req, sock, addr):CODE
LOWgunicorn/workers/gthread.py691 def handle_request(self, req, conn):CODE
Example Usage Blocks5 hits · 8 pts
SeverityFileLineSnippetContext
LOWtests/docker/asgi_framework_compat/docker-compose.yml4# Usage:COMMENT
LOWtests/docker/asgi_framework_compat/scripts/run_tests.sh4# Usage:COMMENT
LOWexamples/readline_app.py7# Usage:COMMENT
LOWexamples/http2_gevent/docker-compose.yml3# Usage:COMMENT
LOWscripts/run_docker_tests.sh14# Usage:COMMENT
AI Structural Patterns4 hits · 4 pts
SeverityFileLineSnippetContext
LOWtests/docker/asgi_compliance/test_http2_asgi.py345CODE
LOWgunicorn/asgi/parser.py145CODE
LOWgunicorn/http/message.py649CODE
LOWexamples/dirty_example/dirty_app.py102CODE
Modern AI Meta-Vocabulary1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMtests/docker/asgi_framework_compat/README.md73├── docker-compose.yml # Container orchestrationCODE
Dead Code1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMtests/dirty/test_worker_streaming.py333CODE
Fake / Example Data1 hit · 1 pts
SeverityFileLineSnippetContext
LOWtests/test_http.py194 fake_sock = t.FakeSocket(io.BytesIO(b'Lorem ipsum dolor'))CODE
AI Slop Vocabulary1 hit · 0 pts
SeverityFileLineSnippetContext
MEDIUMtests/test_arbiter.py175 """Set the 'preload_app' and 'raw_env' settings in order to verify theirSTRING