Sample

pyint-211985934c18-I04

Replace names with deterministic minifier-style shortest identifiers

Matched original source

Lines85

Scores

MethodScoreScale
Posnett00–1; higher is more readable
Dorn0.8710–1; higher is more readable
Mi0.5080–1; higher is more readable
LLOC33Logical lines; fewer is more readable
DeepSeek V4 Pro90–20; mean of three runs
GPT-6.1 Sol11.330–20; mean of three runs
BTTF0.7870–1; higher is more readable

Views

Source code

from __future__ import annotations import os.path import socket # noqa: F401 import typing import warnings from typing import Any from urllib3.exceptions import ( ClosedPoolError, ConnectTimeoutError, LocationValueError, MaxRetryError, NewConnectionError, ProtocolError, ReadTimeoutError, ResponseError, ) from urllib3.exceptions import HTTPError as _HTTPError from urllib3.exceptions import InvalidHeader as _InvalidHeader from urllib3.exceptions import ProxyError as _ProxyError from urllib3.exceptions import SSLError as _SSLError from urllib3.poolmanager import PoolManager, proxy_from_url from urllib3.util import Timeout as TimeoutSauce from urllib3.util import parse_url from urllib3.util.retry import Retry from .auth import _basic_auth_str from .compat import basestring, urlparse from .cookies import extract_cookies_to_jar from .exceptions import ( ConnectionError, ConnectTimeout, InvalidHeader, InvalidProxyURL, InvalidSchema, InvalidURL, ProxyError, ReadTimeout, RetryError, SSLError, ) from .models import Response from .structures import CaseInsensitiveDict from .utils import ( DEFAULT_CA_BUNDLE_PATH, get_auth_from_url, get_encoding_from_headers, prepend_scheme_if_needed, select_proxy, urldefragauth, ) from ._types import is_prepared as _is_prepared class BaseAdapter: """The Base Transport Adapter""" def __init__(self) -> None: super().__init__() def a( self, c: PreparedRequest, d: bool = False, e: _t.TimeoutType = None, f: _t.VerifyType = True, g: _t.CertType = None, h: dict[str, str] | None = None, ) -> Response: """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest <PreparedRequest>` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) <timeouts>` tuple. :type timeout: float or tuple :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. """ raise NotImplementedError def b(self) -> None: """Cleans up adapter specific items.""" raise NotImplementedError

Loading feature diagnosis…

Source regions

Feature contributions

Feature contributions

FeatureValueContribution
(log-odds)
Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones.1816.539−59.946
Source linesThe number of non-empty source lines.85+34
Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value.4.644−6.967

Intercept 8.87 + feature contributions = -24.042 (log-odds).
Score = sigmoid(-24.042) = 0.

Feature contributions

FeatureValueContribution
(log-odds)
Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code.86−2.009
Indentation frequencyHow rapidly indentation changes from line to line.71+1.719
Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom.84.969+0.778
Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right.94.965+0.728
Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *.0.037+0.585
Number layout frequencyHow rapidly the number of numeric values per line changes through the code.1+0.398
Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names.94.93−0.356

Intercept 0.07 + feature contributions = 1.913 (log-odds).
Score = sigmoid(1.913) = 0.871.

Score0.508
Score33
Run 1

The code has good structural elements such as organized imports and clear docstrings, but readability is undermined by vague naming and unnecessary abstraction. The method names 'a' and 'b' and parameter names 'c', 'd', etc. obscure intent, despite the docstrings explaining them. The imports are grouped logically, and the class structure is simple and flat, which helps. However, the misleading or generic naming requires constant cross-referencing with documentation, breaking natural reading flow. The method signature is still reasonably flat, and action granularity is fine, but the overall clarity of intent suffers significantly. Eliminating unused or redundant imports (e.g., socket, typing) would also reduce noise.

Run 2

The imports are organized but excessively long, with multiple unused items (socket, basestring, CaseInsensitiveDict, many exceptions) cluttering the module. The class and method names (BaseAdapter.a, .b) are meaningless and obscure intent, while parameter names (c, d, e, f, g, h) fail to communicate purpose, contradicting the detailed docstring. The docstring references parameter names (request, stream, timeout) that do not match actual parameters, creating confusion. Type hints use undefined names (_t.TimeoutType), further reducing clarity. Nesting is flat and code length is moderate, but the cryptic naming, unused imports, and misleading documentation severely undermine readability. Action granularity and reading flow are adequate within method bodies, but the overall structure lacks logical cohesion. A reader must cross-reference the docstring and infer parameter meanings from context, making the code difficult to maintain. More meaningful names, removal of unused imports, and alignment between documentation and code would significantly improve clarity.

Run 3

The code imports are well-organized, but the class method 'a' uses meaningless single-letter parameter names (c, d, e, f, g, h) that directly contradict the documented parameters (request, stream, timeout, verify, cert, proxies), making the code highly ambiguous. The method name 'a' and 'b' are equally uninformative, obscuring their purpose despite the docstrings. The nested list of imports is somewhat verbose but standard. While the code has flat nesting and one action per line, clarity of intent is severely compromised by the obfuscated naming, which appears intentionally degraded. This makes the code nearly unreadable despite proper structure and formatting, because readers cannot map parameters to their documented meanings without constant cross-referencing.

Run 1

Code Structure: Imports and the adapter class are logically separated, but many imports are unused in this excerpt and distract from the small interface. Nesting: Very flat, with no nested control flow. Clarity of intent: The class and docstrings explain the transport interface, but method names a and b and parameters c through h obscure meaning. Docstring parameter names do not match the signature, and PreparedRequest and _t are not defined or imported in the excerpt, making annotations harder to interpret. Code length: The implementation is concise, but the lengthy import block and documentation dominate the minimal functionality. Action granularity: Statements generally perform one action per line; the multiline signature is easy to scan. Reading flow: Conventional imports followed by a class provide a natural progression, but cryptic identifiers and mismatched documentation interrupt comprehension.

Run 2

Code Structure: Imports and the adapter class are logically organized, but extensive unused imports obscure the small interface. Nesting: Very flat, with no nested control flow. Clarity of intent: The class name, return types, and docstrings establish a transport-adapter purpose, but single-letter method and parameter names are ambiguous. Docstring parameter names do not match the signatures, and PreparedRequest and _t are not defined or imported in the snippet, making annotations harder to interpret. Code length: The actual interface is concise, but the import block and lengthy documentation are disproportionate to the implementation shown. Action granularity: Each statement performs one action, and multiline signatures are easy to scan. Reading flow: Conventional imports followed by a class and methods provide a natural sequence, but irrelevant imports and mismatched documentation interrupt comprehension.

Run 3

Code Structure: Imports are grouped and the adapter class has clearly separated methods, but many imports are irrelevant to the shown implementation. Nesting: Very flat, with no nested control flow. Clarity of intent: Class and docstrings explain the transport interface, but method names a/b and parameter names c–h obscure meaning. Docstring parameter names do not match the signatures, and PreparedRequest and _t are not defined or imported in the snippet, making annotations harder to interpret. Code length: The implementation is concise, but extensive imports and documentation disproportionately outweigh the minimal behavior. Action granularity: Each statement performs one action, and multiline signatures improve scanning. Reading flow: Conventional imports-to-class organization helps, but the large import preamble and mismatch between descriptive documentation and opaque identifiers interrupt comprehension.