Repository Analysis

redis/redis-py

Redis Python client

22.0 Moderate AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of redis/redis-py, a Python project with 13,623 GitHub stars. SynthScan v2.0 examined 203,046 lines of code across 384 source files, recording 4517 pattern matches distributed across 21 syntactic categories. The overall adjusted score of 22.0 places this repository in the Moderate 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).

22.0
Adjusted Score
22.0
Raw Score
100%
Time Factor
2026-08-28
Last Push
13.6K
Stars
Python
Language
203.0K
Lines of Code
384
Files
4.5K
Pattern Hits
2026-08-29
Scan Date
0.29
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

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.

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 2HIGH 109MEDIUM 127LOW 4279

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 4517 distinct pattern matches across 21 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.

Hyper-Verbose Identifiers3333 hits · 2678 pts
SeverityFileLineSnippetContext
LOWtasks.py14def _ensure_junit_results_dir():CODE
LOWtasks.py175def multidb_integration_tests(c, uvloop=False, profile=False):CODE
LOWredis/ocsp.py243 def components_from_direct_connection(self):CODE
LOWredis/keyspace_notifications.py223def _parse_length_prefixed_subkeys(s: str) -> list[str]:CODE
LOWredis/keyspace_notifications.py1095 def subscribe_subkeyspaceitem(CODE
LOWredis/keyspace_notifications.py1106 def subscribe_subkeyspaceevent(CODE
LOWredis/keyspace_notifications.py1410 def subscribe_subkeyspaceitem(CODE
LOWredis/keyspace_notifications.py1432 def subscribe_subkeyspaceevent(CODE
LOWredis/keyspace_notifications.py1911 def _unsubscribe_from_all_nodes(self, channels: list[str], use_punsubscribe: bool):CODE
LOWredis/keyspace_notifications.py2082 def _refresh_subscriptions_on_error(self):CODE
LOWredis/client.py119def add_debug_log_for_operation_failure(connection: "AbstractConnection"):CODE
LOWredis/client.py818 def _send_command_parse_response(self, conn, command_name, *args, **options):CODE
LOWredis/client.py845 def _himport_reconcile_discards(self, conn):CODE
LOWredis/client.py1212 def _resubscribe_shard_channels(self) -> None:CODE
LOWredis/client.py1258 def clean_health_check_responses(self) -> None:CODE
LOWredis/client.py1924 def _disconnect_reset_raise_on_watching(CODE
LOWredis/client.py1963 def immediate_execute_command(self, *args, **options):CODE
LOWredis/client.py2035 def _himport_prepare_pipeline(self, conn, commands):CODE
LOWredis/client.py2186 def _disconnect_raise_on_watching(CODE
LOWredis/background.py198 def _ensure_health_check_loop(self, timeout: float = 5.0):CODE
LOWredis/background.py281 def _call_later_recurring_coro(CODE
LOWredis/background.py469def _start_event_loop_in_thread(CODE
LOWredis/driver_info.py11def _validate_no_invalid_chars(value: str, field_name: str) -> None:CODE
LOWredis/_defaults.py12def get_default_socket_keepalive_options() -> dict[int, int]:CODE
LOWredis/connection.py730 def add_maint_start_notification(self, id: int):CODE
LOWredis/connection.py733 def get_processed_start_notifications(self) -> set:CODE
LOWredis/connection.py736 def add_skipped_end_notification(self, id: int):CODE
LOWredis/connection.py739 def get_skipped_end_notifications(self) -> set:CODE
LOWredis/connection.py742 def reset_received_notifications(self):CODE
LOWredis/connection.py985 def _construct_command_packer(self, packer):CODE
LOWredis/connection.py993 def register_connect_callback(self, callback):CODE
LOWredis/connection.py1699 def register_connect_callback(self, callback):CODE
LOWredis/connection.py1702 def deregister_connect_callback(self, callback):CODE
LOWredis/connection.py1708 def set_maint_notifications_pool_handler_for_connection(CODE
LOWredis/connection.py1716 def set_maint_notifications_cluster_handler_for_connection(CODE
LOWredis/connection.py2062 def _enable_tracking_callback(self, conn: ConnectionInterface) -> None:CODE
LOWredis/connection.py2067 def _process_pending_invalidations(self):CODE
LOWredis/connection.py2076 def _on_invalidation_callback(self, data: List[Union[str, Optional[List[bytes]]]]):CODE
LOWredis/connection.py207 def register_connect_callback(self, callback):CODE
LOWredis/connection.py211 def deregister_connect_callback(self, callback):CODE
LOWredis/connection.py307 def extract_connection_details(self) -> str:CODE
LOWredis/connection.py386 def _get_push_notifications_parser(self) -> Union[_HiredisParser, _RESP3Parser]:CODE
LOWredis/connection.py460 def _configure_maintenance_notifications(CODE
LOWredis/connection.py550 def set_maint_notifications_pool_handler_for_connection(CODE
LOWredis/connection.py584 def set_maint_notifications_cluster_handler_for_connection(CODE
LOWredis/connection.py616 def activate_maint_notifications_handling_if_enabled(self, check_health=True):CODE
LOWredis/connection.py636 def _enable_maintenance_notifications(CODE
LOWredis/connection.py755 def update_current_socket_timeout(self, relaxed_timeout: Optional[float] = None):CODE
LOWredis/connection.py1005 def deregister_connect_callback(self, callback):CODE
LOWredis/connection.py1522 def extract_connection_details(self) -> str:CODE
LOWredis/connection.py1929 def _himport_reconciled_revision(self):CODE
LOWredis/connection.py1933 def _himport_reconciled_revision(self, value):CODE
LOWredis/connection.py1980 def _maint_notifications_connection_handler(CODE
LOWredis/connection.py1987 def _maint_notifications_connection_handler(CODE
LOWredis/connection.py2000 def _get_maint_notifications_connection_instance(CODE
LOWredis/connection.py2036 def update_current_socket_timeout(self, relaxed_timeout: Optional[float] = None):CODE
LOWredis/connection.py2090 def extract_connection_details(self) -> str:CODE
LOWredis/connection.py2570 def maint_notifications_enabled(self):CODE
LOWredis/connection.py2590 def update_maint_notifications_config(CODE
LOWredis/connection.py2649 def _update_connection_kwargs_for_maint_notifications(CODE
3273 more matches not shown…
Cross-File Repetition97 hits · 485 pts
SeverityFileLineSnippetContext
HIGHredis/client.py0return a connection pool configured from the given url. for example:: redis://[[username]:[password]]@localhost:6379/0 rSTRING
HIGHredis/cluster.py0return a connection pool configured from the given url. for example:: redis://[[username]:[password]]@localhost:6379/0 rSTRING
HIGHredis/asyncio/client.py0return a connection pool configured from the given url. for example:: redis://[[username]:[password]]@localhost:6379/0 rSTRING
HIGHredis/connection.py0return a connection pool configured from the given url. for example:: redis://[[username]:[password]]@localhost:6379/0 rSTRING
HIGHredis/asyncio/connection.py0return a connection pool configured from the given url. for example:: redis://[[username]:[password]]@localhost:6379/0 rSTRING
HIGHredis/client.py0convenience method for executing the callable `func` as a transaction while watching all keys specified in `watches`. thSTRING
HIGHredis/cluster.py0convenience method for executing the callable `func` as a transaction while watching all keys specified in `watches`. thSTRING
HIGHredis/asyncio/client.py0convenience method for executing the callable `func` as a transaction while watching all keys specified in `watches`. thSTRING
HIGHredis/asyncio/cluster.py0convenience method for executing the callable `func` as a transaction while watching all keys specified in `watches`. thSTRING
HIGHredis/client.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/cluster.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/asyncio/client.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/asyncio/cluster.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/lock.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/asyncio/lock.py0create a new lock instance named ``name`` using the redis client supplied by ``redis``. ``timeout`` indicates a maximum STRING
HIGHredis/client.py0return a publish/subscribe object. with this object, you can subscribe to channels and listen for messages that get publSTRING
HIGHredis/multidb/client.py0return a publish/subscribe object. with this object, you can subscribe to channels and listen for messages that get publSTRING
HIGHredis/asyncio/client.py0return a publish/subscribe object. with this object, you can subscribe to channels and listen for messages that get publSTRING
HIGHredis/asyncio/multidb/client.py0return a publish/subscribe object. with this object, you can subscribe to channels and listen for messages that get publSTRING
HIGHredis/client.py0unsubscribe from the supplied patterns. if empty, unsubscribe from all patterns.STRING
HIGHredis/multidb/client.py0unsubscribe from the supplied patterns. if empty, unsubscribe from all patterns.STRING
HIGHredis/asyncio/client.py0unsubscribe from the supplied patterns. if empty, unsubscribe from all patterns.STRING
HIGHredis/asyncio/multidb/client.py0unsubscribe from the supplied patterns. if empty, unsubscribe from all patterns.STRING
HIGHredis/client.py0unsubscribe from the supplied channels. if empty, unsubscribe from all channelsSTRING
HIGHredis/multidb/client.py0unsubscribe from the supplied channels. if empty, unsubscribe from all channelsSTRING
HIGHredis/asyncio/client.py0unsubscribe from the supplied channels. if empty, unsubscribe from all channelsSTRING
HIGHredis/asyncio/multidb/client.py0unsubscribe from the supplied channels. if empty, unsubscribe from all channelsSTRING
HIGHredis/client.py0unsubscribe from the supplied shard_channels. if empty, unsubscribe from all shard_channelsSTRING
HIGHredis/multidb/client.py0unsubscribe from the supplied shard_channels. if empty, unsubscribe from all shard_channelsSTRING
HIGHredis/asyncio/client.py0unsubscribe from the supplied shard_channels. if empty, unsubscribe from all shard_channelsSTRING
HIGHredis/client.py0get the next message if one is available, otherwise none. if timeout is specified, the system will wait for `timeout` seSTRING
HIGHredis/multidb/client.py0get the next message if one is available, otherwise none. if timeout is specified, the system will wait for `timeout` seSTRING
HIGHredis/asyncio/client.py0get the next message if one is available, otherwise none. if timeout is specified, the system will wait for `timeout` seSTRING
HIGHredis/asyncio/multidb/client.py0get the next message if one is available, otherwise none. if timeout is specified, the system will wait for `timeout` seSTRING
HIGHredis/client.py0start a transactional block of the pipeline after watch commands are issued. end the transactional block with `execute`.STRING
HIGHredis/cluster.py0start a transactional block of the pipeline after watch commands are issued. end the transactional block with `execute`.STRING
HIGHredis/asyncio/client.py0start a transactional block of the pipeline after watch commands are issued. end the transactional block with `execute`.STRING
HIGHredis/asyncio/cluster.py0start a transactional block of the pipeline after watch commands are issued. end the transactional block with `execute`.STRING
HIGHredis/client.py0stage a command to be executed when execute() is next called returns the current pipeline object back so commands can beSTRING
HIGHredis/cluster.py0stage a command to be executed when execute() is next called returns the current pipeline object back so commands can beSTRING
HIGHredis/multidb/client.py0stage a command to be executed when execute() is next called returns the current pipeline object back so commands can beSTRING
HIGHredis/asyncio/client.py0stage a command to be executed when execute() is next called returns the current pipeline object back so commands can beSTRING
HIGHredis/asyncio/multidb/client.py0stage a command to be executed when execute() is next called returns the current pipeline object back so commands can beSTRING
HIGHredis/connection.py0update the connection kwargs for all future connections.STRING
HIGHredis/cluster.py0update the connection kwargs for all future connections.STRING
HIGHredis/asyncio/connection.py0update the connection kwargs for all future connections.STRING
HIGHredis/connection.py0dummy functions, needs to be passed as error callback to retry object. :param error: :return:STRING
HIGHredis/asyncio/connection.py0dummy functions, needs to be passed as error callback to retry object. :param error: :return:STRING
HIGHredis/asyncio/cluster.py0dummy functions, needs to be passed as error callback to retry object. :param error: :return:STRING
HIGHredis/cluster.py0the client's himport fieldset registry (empty if none was declared). read-only: the registry is mutated only through theSTRING
HIGHredis/asyncio/cluster.py0the client's himport fieldset registry (empty if none was declared). read-only: the registry is mutated only through theSTRING
HIGHredis/asyncio/client.py0the client's himport fieldset registry (empty if none was declared). read-only: the registry is mutated only through theSTRING
HIGHredis/observability/metrics.py0record a geo failover. args: fail_from: database failed from fail_to: database failed to reason: reason for the failoverSTRING
HIGHredis/observability/recorder.py0record a geo failover. args: fail_from: database failed from fail_to: database failed to reason: reason for the failoverSTRING
HIGHredis/asyncio/observability/recorder.py0record a geo failover. args: fail_from: database failed from fail_to: database failed to reason: reason for the failoverSTRING
HIGHredis/observability/metrics.py0record the lag of a streaming message. args: lag_seconds: lag in seconds stream_name: stream name consumer_group: consumSTRING
HIGHredis/observability/recorder.py0record the lag of a streaming message. args: lag_seconds: lag in seconds stream_name: stream name consumer_group: consumSTRING
HIGHredis/asyncio/observability/recorder.py0record the lag of a streaming message. args: lag_seconds: lag in seconds stream_name: stream name consumer_group: consumSTRING
HIGHtests/test_pubsub.py0create a mock meter that tracks all instrument calls.STRING
HIGHtests/test_cluster.py0create a mock meter that tracks all instrument calls.STRING
37 more matches not shown…
Excessive Try-Catch Wrapping248 hits · 239 pts
SeverityFileLineSnippetContext
LOWdoctests/query_em.py48except Exception:CODE
LOWdoctests/query_em.py56except Exception:CODE
LOWdoctests/query_em.py92except Exception:CODE
LOWdoctests/search_quickstart.py24except Exception:CODE
LOWredis/keyspace_notifications.py1735 except Exception:CODE
LOWredis/keyspace_notifications.py1839 except Exception:CODE
LOWredis/keyspace_notifications.py1889 except Exception:CODE
LOWredis/keyspace_notifications.py1927 except Exception:CODE
LOWredis/keyspace_notifications.py2093 except Exception:CODE
LOWredis/keyspace_notifications.py2106 except Exception:CODE
LOWredis/keyspace_notifications.py2157 except Exception:CODE
MEDIUMredis/client.py797def __del__(self):CODE
MEDIUMredis/client.py1178def __del__(self) -> None:CODE
MEDIUMredis/client.py1865def __del__(self):CODE
LOWredis/client.py800 except Exception:CODE
LOWredis/client.py929 except Exception as e:CODE
LOWredis/client.py1184 except Exception:CODE
LOWredis/client.py1347 except Exception as e:CODE
LOWredis/client.py1868 except Exception:CODE
LOWredis/client.py2008 except Exception as e:CODE
LOWredis/client.py2271 except Exception as e:CODE
LOWredis/background.py252 except Exception:CODE
LOWredis/background.py276 except Exception:CODE
LOWredis/background.py342 except Exception:CODE
LOWredis/background.py408 except Exception:CODE
LOWredis/background.py456 except Exception:CODE
LOWredis/background.py493 except Exception:CODE
MEDIUMredis/connection.py975def __del__(self):CODE
LOWredis/connection.py978 except Exception:CODE
LOWredis/connection.py661 except Exception as e:CODE
LOWredis/connection.py3279 except Exception:CODE
LOWredis/connection.py3682 except Exception:CODE
LOWredis/connection.py3724 except Exception:CODE
LOWredis/connection.py3756 except Exception:CODE
LOWredis/connection.py3807 except Exception:CODE
LOWredis/connection.py3914 except Exception:CODE
LOWredis/connection.py3939 except Exception:CODE
MEDIUMredis/cluster.py1067def __del__(self):CODE
MEDIUMredis/cluster.py2175def close(self) -> None:CODE
MEDIUMredis/cluster.py3209def _get_node_pubsub(self, node):CODE
LOWredis/cluster.py1070 except Exception:CODE
LOWredis/cluster.py1736 except Exception as e:CODE
LOWredis/cluster.py2085 except Exception as e:CODE
LOWredis/cluster.py2482 except Exception as exc:CODE
LOWredis/cluster.py2819 except Exception as e:CODE
LOWredis/cluster.py2924 except Exception as e:CODE
LOWredis/cluster.py3003 except Exception as e:CODE
LOWredis/cluster.py3303 except Exception:CODE
LOWredis/cluster.py3446 except Exception:CODE
LOWredis/cluster.py3495 except Exception:CODE
LOWredis/cluster.py3594 except Exception:CODE
LOWredis/cluster.py3782 except Exception:CODE
LOWredis/cluster.py4860 except Exception as e:CODE
LOWredis/sentinel.py331 except Exception as e:CODE
LOWredis/auth/token_manager.py295 except Exception as e:CODE
LOWredis/auth/token_manager.py305 except Exception as e:CODE
LOWredis/auth/token_manager.py338 except Exception as e:CODE
LOWredis/auth/token_manager.py348 except Exception as e:CODE
MEDIUMredis/auth/token_manager.py214def acquire_token(self, force_refresh=False) -> TokenResponse:CODE
LOWredis/multidb/client.py89 except Exception:CODE
188 more matches not shown…
Self-Referential Comments65 hits · 204 pts
SeverityFileLineSnippetContext
MEDIUMdoctests/dt_vec_set.py263# Create a list of 300 arbitrary values.COMMENT
MEDIUMredis/keyspace_notifications.py1636 # Create the PubSub instance with ignore_subscribe_messages=FalseCOMMENT
MEDIUMredis/background.py228 # Create a new event loop for health checksCOMMENT
MEDIUMredis/connection.py3421 # Create the connection first, then record metrics only on successCOMMENT
MEDIUMredis/cluster.py2633 # Create a redis node with a custom connection poolCOMMENT
MEDIUMredis/cluster.py2774 # Create a new Redis connectionCOMMENT
MEDIUMredis/commands/json/path.py2 """This class represents a path in a JSON value."""STRING
MEDIUMtests/test_search.py1239 # Creating the index definitionCOMMENT
MEDIUMtests/test_search.py1249 # Creating the index definitionCOMMENT
MEDIUMtests/test_search.py577 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_search.py851 # Creating a client with one indexCOMMENT
MEDIUMtests/test_search.py958 # Creating the index definition with sortable and no_stemCOMMENT
MEDIUMtests/test_search.py972 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_search.py2429 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_connection_pool.py1388 # Create a connection that doesn't belong to this poolCOMMENT
MEDIUMtests/test_cluster.py258 # Create a subclass of RedisCluster that overrides __del__COMMENT
MEDIUMtests/test_cluster.py805 # Create a cluster with reading from replicationsCOMMENT
MEDIUMtests/test_cluster.py5000 # Create a cluster with reading from replicationsCOMMENT
MEDIUMtests/test_cluster.py5171 # Create a new event dispatcher and attach it to the clusterCOMMENT
MEDIUMtests/test_cluster.py5384 # Create a new event dispatcher and attach it to the clusterCOMMENT
MEDIUMtests/test_cache.py1849 # Create a cache with max_size=2COMMENT
MEDIUMtests/test_keyspace_notifications.py380 # Create a mock redis connection with pubsubCOMMENT
MEDIUMtests/test_keyspace_notifications.py626 # Create a new pubsub for the re-creationCOMMENT
MEDIUMtests/test_max_connections_error.py78 # Create a more complete mock clusterCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py987 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py995 # Create a migrating notification (not handled by pool handler)COMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py611 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py670 # Create a Redis client with disabled maintenance notifications configurationCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py685 # Create a new enabled configuration and set up pool handlerCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py700 # Create a new connection and validate it has full handlersCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py875 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py959 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1039 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1126 # Create a pool and Redis client with disabled relaxed timeout configCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1237 # Create a pool and Redis client with maintenance notificationsCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1319 # Create a pool and Redis client with maintenance notifications and pool handlerCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1451 # Create a pool and Redis client with maintenance notifications and pool handlerCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1598 # Create a pool and Redis client with maintenance notifications and pool handlerCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1681 # Create a pool and Redis client with maintenance notifications and pool handlerCOMMENT
MEDIUM…int_notifications/test_maint_notifications_handling.py1745 # Create a pool and Redis client with maintenance notifications and pool handlerCOMMENT
MEDIUMtests/test_multidb/test_client.py465 # Create a DatabaseConfig for the new database with highest weightCOMMENT
MEDIUMtests/test_observability/test_recorder.py285 # Create a mock connection poolCOMMENT
MEDIUMtests/test_observability/test_recorder.py1601 # Create a mock cache size callbackCOMMENT
MEDIUM…st_observability/test_metrics_connection_attributes.py126 # Create a ConnectionPool with MockConnectionWithoutHostPort as connection_classCOMMENT
MEDIUMtests/test_asyncio/test_search.py589 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_asyncio/test_search.py887 # Creating a client with one indexCOMMENT
MEDIUMtests/test_asyncio/test_search.py1046 # Creating the index definition with sortable and no_stemCOMMENT
MEDIUMtests/test_asyncio/test_search.py1062 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_asyncio/test_search.py1785 # Creating the index definition and schemaCOMMENT
MEDIUMtests/test_asyncio/test_commands.py6620 # Create an empty stream by adding and deleting a messageCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py3909 # Create a mock connection marked for reconnectCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py3924 # Create a mock connection NOT marked for reconnectCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py215 # Create a subclass of RedisCluster that overrides __del__COMMENT
MEDIUMtests/test_asyncio/test_cluster.py923 # Create a cluster with reading from replicationsCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py4099 # Define a custom callbackCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py4540 # Create a cluster with reading from replicationsCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py4850 # Create a new event dispatcher and attach it to the clusterCOMMENT
MEDIUMtests/test_asyncio/test_cluster.py5050 # Create a new event dispatcher and attach it to the clusterCOMMENT
MEDIUMtests/test_asyncio/test_client.py42 # Create a real Retry object that just executes the function directlyCOMMENT
MEDIUMtests/test_asyncio/test_client.py238 # Create a real Retry object that just executes the function directlyCOMMENT
5 more matches not shown…
Unused Imports178 hits · 146 pts
SeverityFileLineSnippetContext
LOWdoctests/query_range.py4CODE
LOWdoctests/query_geo.py4CODE
LOWdoctests/query_ft.py4CODE
LOWdoctests/query_ft.py7CODE
LOWdoctests/query_ft.py7CODE
LOWdoctests/query_ft.py9CODE
LOWredis/keyspace_notifications.py59CODE
LOWredis/client.py31CODE
LOWredis/client.py101CODE
LOWredis/__init__.py1CODE
LOWredis/__init__.py2CODE
LOWredis/__init__.py3CODE
LOWredis/__init__.py3CODE
LOWredis/__init__.py4CODE
LOWredis/__init__.py5CODE
LOWredis/__init__.py6CODE
LOWredis/__init__.py6CODE
LOWredis/__init__.py6CODE
LOWredis/__init__.py6CODE
LOWredis/__init__.py6CODE
LOWredis/__init__.py13CODE
LOWredis/__init__.py13CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py14CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py30CODE
LOWredis/__init__.py50CODE
LOWredis/__init__.py50CODE
LOWredis/__init__.py50CODE
LOWredis/__init__.py50CODE
LOWredis/__init__.py56CODE
LOWredis/__init__.py57CODE
118 more matches not shown…
Deep Nesting182 hits · 128 pts
SeverityFileLineSnippetContext
LOWredis/ocsp.py22CODE
LOWredis/keyspace_notifications.py974CODE
LOWredis/keyspace_notifications.py1853CODE
LOWredis/keyspace_notifications.py2020CODE
LOWredis/keyspace_notifications.py2109CODE
LOWredis/client.py640CODE
LOWredis/client.py1651CODE
LOWredis/cache.py215CODE
LOWredis/connection.py2373CODE
LOWredis/connection.py1127CODE
LOWredis/connection.py1449CODE
LOWredis/connection.py1577CODE
LOWredis/connection.py1769CODE
LOWredis/connection.py2698CODE
LOWredis/connection.py2758CODE
LOWredis/connection.py2819CODE
LOWredis/connection.py3216CODE
LOWredis/connection.py3634CODE
LOWredis/connection.py3697CODE
LOWredis/utils.py358CODE
LOWredis/cluster.py1206CODE
LOWredis/cluster.py1633CODE
LOWredis/cluster.py1810CODE
LOWredis/cluster.py2214CODE
LOWredis/cluster.py2325CODE
LOWredis/cluster.py2432CODE
LOWredis/cluster.py2688CODE
LOWredis/cluster.py2956CODE
LOWredis/cluster.py3251CODE
LOWredis/cluster.py3366CODE
LOWredis/cluster.py3394CODE
LOWredis/cluster.py3467CODE
LOWredis/cluster.py4045CODE
LOWredis/cluster.py4353CODE
LOWredis/cluster.py5108CODE
LOWredis/maint_notifications.py863CODE
LOWredis/maint_notifications.py1139CODE
LOWredis/observability/recorder.py542CODE
LOWredis/commands/core.py386CODE
LOWredis/commands/core.py2896CODE
LOWredis/commands/core.py4330CODE
LOWredis/commands/cluster.py1449CODE
LOWredis/commands/helpers.py73CODE
LOWredis/commands/search/result.py15CODE
LOWredis/commands/search/commands.py510CODE
LOWredis/commands/search/commands.py706CODE
LOWredis/commands/search/commands.py844CODE
LOWredis/commands/search/commands.py864CODE
LOWredis/commands/vectorset/utils.py74CODE
LOWredis/asyncio/keyspace_notifications.py447CODE
LOWredis/asyncio/keyspace_notifications.py714CODE
LOWredis/asyncio/keyspace_notifications.py880CODE
LOWredis/asyncio/client.py1634CODE
LOWredis/asyncio/client.py1849CODE
LOWredis/asyncio/client.py2026CODE
LOWredis/asyncio/connection.py1800CODE
LOWredis/asyncio/connection.py946CODE
LOWredis/asyncio/connection.py1257CODE
LOWredis/asyncio/connection.py1402CODE
LOWredis/asyncio/connection.py1500CODE
122 more matches not shown…
Decorative Section Separators30 hits · 105 pts
SeverityFileLineSnippetContext
MEDIUMredis/himport.py30# ---------------------------------------------------------------------------COMMENT
MEDIUMredis/himport.py32# ---------------------------------------------------------------------------COMMENT
MEDIUMredis/keyspace_notifications.py1739# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py1741# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py103# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py105# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py543# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py545# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py1026# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py1028# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py1597# =============================================================================COMMENT
MEDIUMredis/keyspace_notifications.py1599# =============================================================================COMMENT
MEDIUMredis/commands/metadata.py956# =============================================================================COMMENT
MEDIUMredis/commands/metadata.py958# =============================================================================COMMENT
MEDIUMredis/commands/policies.py42# =====================================================================================COMMENT
MEDIUMredis/commands/policies.py59# =====================================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py75# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py77# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py604# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py606# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py219# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py221# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py481# =============================================================================COMMENT
MEDIUMredis/asyncio/keyspace_notifications.py483# =============================================================================COMMENT
MEDIUMredis/_parsers/commands.py418# =============================================================================COMMENT
MEDIUMredis/_parsers/commands.py420# =============================================================================COMMENT
MEDIUMtests/test_sentinel.py502# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_sentinel.py504# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_asyncio/test_sentinel.py483# ---------------------------------------------------------------------------COMMENT
MEDIUMtests/test_asyncio/test_sentinel.py485# ---------------------------------------------------------------------------COMMENT
Over-Commented Block92 hits · 81 pts
SeverityFileLineSnippetContext
LOWdoctests/dt_stream.py41res4 = r.xrange("race:france", "1691765278160-0", "+", 2)COMMENT
LOWdoctests/dt_stream.py61# [('1692629576966-0',COMMENT
LOWdoctests/dt_stream.py101 print(e) # >>> WRONGIDCOMMENT
LOWdoctests/dt_stream.py121# {'rider': 'Prickett', 'speed': '29.7', 'position': '2', 'location_id': '1'}COMMENT
LOWdoctests/dt_stream.py141# STEP_START xrange_step_1COMMENT
LOWdoctests/dt_stream.py161# >>> [COMMENT
LOWdoctests/dt_stream.py181# >>> [COMMENT
LOWdoctests/dt_stream.py261)COMMENT
LOWdoctests/dt_stream.py281 res25COMMENT
LOWdoctests/dt_stream.py321# STEP_START xautoclaim_cursorCOMMENT
LOWdoctests/dt_stream.py341print(COMMENT
LOWdoctests/query_geo.py61# REMOVE_STARTCOMMENT
LOWdoctests/query_ft.py41assert res.total == 2COMMENT
LOWdoctests/query_ft.py61# STEP_ENDCOMMENT
LOWdoctests/query_ft.py81# REMOVE_STARTCOMMENT
LOWdoctests/cmds_list.py121r.delete("mylist")COMMENT
LOWdoctests/query_em.py101print(res.total)COMMENT
LOWdoctests/dt_bitmap.py141# >>> 01011000COMMENT
LOWdoctests/search_quickstart.py221# STEP_START query_single_termCOMMENT
LOWdoctests/search_quickstart.py241# STEP_START query_single_term_limit_fieldsCOMMENT
LOWdoctests/search_quickstart.py261# ...COMMENT
LOWdoctests/search_quickstart.py281# ...COMMENT
LOWdoctests/search_quickstart.py301# 'json': '{COMMENT
LOWdoctests/search_quickstart.py321# >>> Result{1 total, docs: [COMMENT
LOWdoctests/search_quickstart.py341# >>> Result{1 total, docs: [COMMENT
LOWdoctests/search_quickstart.py361# >>> Result{1 total, docs: [COMMENT
LOWdoctests/search_quickstart.py381# >>> {COMMENT
LOWdoctests/search_quickstart.py421# ['condition', 'new', 'count', '5']]COMMENT
LOWdoctests/query_combined.py121# REMOVE_STARTCOMMENT
LOWdoctests/search_vss.py61res = pipeline.execute()COMMENT
LOWdoctests/search_vss.py101# >>> [True, True, True, True, True, True, True, True, True, True, True]COMMENT
LOWdoctests/search_vss.py161# >>> 11 documents indexed with 0 failuresCOMMENT
LOWdoctests/search_vss.py181assert all(COMMENT
LOWdoctests/search_vss.py201# 'brand': 'Peaknetic',COMMENT
LOWdoctests/search_vss.py221# 'id': 'bikes:009',COMMENT
LOWutil/wait-for-it.sh1#!/usr/bin/env bashCOMMENT
LOWredis/himport.py201 # Serializes mutations (prepare/discard/discard_all) so the revision bump andCOMMENT
LOWredis/client.py821 """COMMENT
LOWredis/cache.py361COMMENT
LOWredis/connection.py3281COMMENT
LOWredis/connection.py3301 # there is an extremely small chance this could fail in the followingCOMMENT
LOWredis/cluster.py2461 # the slot's node listCOMMENT
LOWredis/cluster.py3061 # connection used by aclose / send_command / regular subscribe) soCOMMENT
LOWredis/cluster.py3281 with self._shard_state_lock:COMMENT
LOWredis/cluster.py3461 # symptoms of the same unreachable node) so the worker's done-COMMENT
LOWredis/cluster.py3481 # (e.g. removed by failover / topology refresh): noCOMMENT
LOWredis/cluster.py3561 returnCOMMENT
LOWredis/cluster.py4041 except (ConnectionError, TimeoutError) as e:COMMENT
LOWredis/cluster.py4521 )COMMENT
LOWredis/cluster.py4561 # and allows us to be more confident in correctness of behavior.COMMENT
LOWredis/cluster.py4881 # HIMPORT SET's wire form depends on per-connection state: the fieldsetCOMMENT
LOWredis/commands/metadata.py881# only discoverable through key specs, so ``first_key_pos`` is 0 and the derived policies comeCOMMENT
LOWredis/commands/metadata.py901# its reply is what the caller waited for rather than a snapshot the cache may re-serve.COMMENT
LOWredis/commands/metadata.py961# Every entry below was validated against a live ``COMMAND`` reply from Redis 8.10.0 withCOMMENT
LOWredis/commands/metadata.py981# ``blocking`` command flag.COMMENT
LOWredis/commands/metadata.py1001 "eval_ro": _SCRIPT_RUNNER_MOVABLE_KEYS,COMMENT
LOWredis/commands/metadata.py1061 "sunion": _CACHEABLE_KEYED,COMMENT
LOWredis/commands/metadata.py1081 has_key_argument=True,COMMENT
LOWredis/commands/policies.py41COMMENT
LOWredis/commands/search/commands.py141 }COMMENT
32 more matches not shown…
AI Structural Patterns93 hits · 69 pts
SeverityFileLineSnippetContext
LOWredis/client.py270CODE
LOWredis/connection.py329CODE
LOWredis/connection.py810CODE
LOWredis/connection.py2100CODE
LOWredis/connection.py2819CODE
LOWredis/cluster.py716CODE
LOWredis/cluster.py2325CODE
LOWredis/cluster.py3655CODE
LOWredis/observability/metrics.py479CODE
LOWredis/observability/config.py105CODE
LOWredis/http/http_client.py64CODE
LOWredis/commands/core.py347CODE
LOWredis/commands/core.py367CODE
LOWredis/commands/core.py386CODE
LOWredis/commands/core.py3405CODE
LOWredis/commands/core.py3423CODE
LOWredis/commands/core.py3440CODE
LOWredis/commands/core.py4292CODE
LOWredis/commands/core.py4311CODE
LOWredis/commands/core.py4330CODE
LOWredis/commands/core.py5364CODE
LOWredis/commands/core.py5378CODE
LOWredis/commands/core.py5391CODE
LOWredis/commands/core.py6939CODE
LOWredis/commands/core.py6955CODE
LOWredis/commands/core.py6970CODE
LOWredis/commands/core.py10017CODE
LOWredis/commands/core.py10033CODE
LOWredis/commands/core.py10048CODE
LOWredis/commands/core.py11604CODE
LOWredis/commands/core.py11622CODE
LOWredis/commands/core.py11639CODE
LOWredis/commands/core.py11703CODE
LOWredis/commands/core.py11720CODE
LOWredis/commands/core.py11736CODE
LOWredis/commands/core.py11822CODE
LOWredis/commands/core.py11841CODE
LOWredis/commands/core.py11859CODE
LOWredis/commands/core.py11941CODE
LOWredis/commands/core.py11959CODE
LOWredis/commands/core.py11976CODE
LOWredis/commands/timeseries/commands.py236CODE
LOWredis/commands/timeseries/commands.py252CODE
LOWredis/commands/timeseries/commands.py267CODE
LOWredis/commands/timeseries/commands.py396CODE
LOWredis/commands/timeseries/commands.py411CODE
LOWredis/commands/timeseries/commands.py425CODE
LOWredis/commands/timeseries/commands.py518CODE
LOWredis/commands/timeseries/commands.py533CODE
LOWredis/commands/timeseries/commands.py547CODE
LOWredis/commands/timeseries/commands.py774CODE
LOWredis/commands/timeseries/commands.py792CODE
LOWredis/commands/timeseries/commands.py809CODE
LOWredis/commands/timeseries/commands.py887CODE
LOWredis/commands/timeseries/commands.py905CODE
LOWredis/commands/timeseries/commands.py922CODE
LOWredis/commands/timeseries/commands.py1122CODE
LOWredis/commands/timeseries/commands.py1140CODE
LOWredis/commands/timeseries/commands.py1157CODE
LOWredis/commands/timeseries/commands.py1258CODE
33 more matches not shown…
Redundant / Tautological Comments41 hits · 61 pts
SeverityFileLineSnippetContext
LOWutil/wait-for-it.sh172 # Check if busybox timeout uses -t flagCOMMENT
LOWredis/keyspace_notifications.py1987 # Check if we've exceeded the total timeoutCOMMENT
LOWredis/connection.py1851 # Check if command response exists in a cache and it's not in progress.COMMENT
LOWredis/cluster.py2897 # Check if the slots are not fully coveredCOMMENT
LOWredis/sentinel.py285 # Check if command is supposed to return the originalCOMMENT
LOWredis/sentinel.py346 # Check if our sentinel doesn't see other nodesCOMMENT
LOWredis/maint_notifications.py712 # Check if the host is an IP addressCOMMENT
LOWredis/maint_notifications.py921 # Set state to MOVINGCOMMENT
LOWredis/observability/metrics.py512 # Check if this command should be trackedCOMMENT
LOWredis/observability/recorder.py476 # Check if channel names should be hiddenCOMMENT
LOWredis/observability/recorder.py520 # Check if stream names should be hiddenCOMMENT
LOWredis/observability/recorder.py571 # Check if stream names should be hiddenCOMMENT
LOWredis/observability/providers.py88 # Check if it's a real provider (not NoOp)COMMENT
LOWredis/asyncio/cluster.py2393 # Check if the slots are not fully coveredCOMMENT
LOWredis/asyncio/cluster.py3032 # Check if it has a command that failed with a relevantCOMMENT
LOWredis/asyncio/sentinel.py242 # Check if command is supposed to return the originalCOMMENT
LOWredis/asyncio/sentinel.py306 # Check if our sentinel doesn't see other nodesCOMMENT
LOWredis/asyncio/observability/recorder.py437 # Check if channel names should be hiddenCOMMENT
LOWredis/asyncio/observability/recorder.py474 # Check if stream names should be hiddenCOMMENT
LOWredis/asyncio/observability/recorder.py514 # Check if stream names should be hiddenCOMMENT
LOWredis/_parsers/commands.py545 # Check if this is a policy stringCOMMENT
LOWtests/test_connect.py125 # Check if the base class defaults were taken over.COMMENT
LOWtests/test_connect.py128 # Verify if the timeout and the path is set correctly.COMMENT
LOWtests/test_vsets.py762 # Set attributes to NoneCOMMENT
LOWtests/test_vsets.py768 # Set attributes to empty dictCOMMENT
LOWtests/test_vsets.py780 # Set attributes to unexisting elementCOMMENT
LOWtests/test_vsets.py786 # Set attributes to unexisting vsetCOMMENT
LOWtests/test_cluster.py5574 # Check if any has error.type (the one from _raise_first_error)COMMENT
LOW…int_notifications/test_maint_notifications_handling.py219 # Check if this is a key that should trigger a push messageCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py406 # Check if any of the sockets in rlist have data availableCOMMENT
LOWtests/test_parsers/test_errors.py139 # Check if any of the sockets in rlist have data availableCOMMENT
LOWtests/test_multidb/conftest.py36 # Check if the test is marked to skip connection mockingCOMMENT
LOWtests/test_asyncio/test_vsets.py762 # Set attributes to NoneCOMMENT
LOWtests/test_asyncio/test_vsets.py768 # Set attributes to empty dictCOMMENT
LOWtests/test_asyncio/test_vsets.py780 # Set attributes to unexisting elementCOMMENT
LOWtests/test_asyncio/test_vsets.py786 # Set attributes to unexisting vsetCOMMENT
LOWtests/test_asyncio/test_connection_pool.py273 # Check if the pool's lock is held during connectionCOMMENT
LOWtests/test_asyncio/test_multidb/conftest.py35 # Check if the test is marked to skip connection mockingCOMMENT
LOWbenchmarks/otel_benchmark.py1235 # Output resultsCOMMENT
LOWbenchmarks/otel_benchmark.py1264 # Output resultsCOMMENT
LOW.github/actions/run-tests/action.yml99 # Check if REDIS_VERSION is in the custom mapCOMMENT
Modern Structural Boilerplate59 hits · 56 pts
SeverityFileLineSnippetContext
LOWredis/crc.py9__all__ = ["key_slot", "REDIS_CLUSTER_HASH_SLOTS"]CODE
LOWredis/credentials.py5logger = logging.getLogger(__name__)CODE
LOWredis/keyspace_notifications.py80logger = logging.getLogger(__name__)CODE
LOWredis/client.py112logger = logging.getLogger(__name__)CODE
LOWredis/client.py597 def set_retry(self, retry: Retry) -> None:CODE
LOWredis/client.py601 def set_response_callback(self, command: str, callback: Callable) -> None:CODE
LOWredis/cache.py466 def set_metadata_resolver(self, metadata_resolver: MetadataResolver) -> None:CODE
LOWredis/__init__.py72__all__ = [CODE
LOWredis/retry.py55 def update_supported_errors(self, specified_errors: Iterable[Type[E]]) -> None:CODE
LOWredis/retry.py69 def update_retries(self, value: int) -> None:CODE
LOWredis/connection.py3520 def set_retry(self, retry: Retry) -> None:CODE
LOWredis/cluster.py118logger = logging.getLogger(__name__)CODE
LOWredis/cluster.py1241 def set_retry(self, retry: Retry) -> None:CODE
LOWredis/lock.py11logger = logging.getLogger(__name__)CODE
LOWredis/maint_notifications.py30logger = logging.getLogger(__name__)CODE
LOWredis/auth/token_manager.py12logger = logging.getLogger(__name__)CODE
LOWredis/multidb/client.py34logger = logging.getLogger(__name__)CODE
LOWredis/multidb/client.py139 def set_active_database(self, database: SyncDatabase) -> None:CODE
LOWredis/multidb/failover.py23 def set_databases(self, databases: Databases) -> None:CODE
LOWredis/multidb/failover.py68 def set_databases(self, databases: Databases) -> None:CODE
LOWredis/multidb/failure_detector.py26 def set_command_executor(self, command_executor) -> None:CODE
LOWredis/multidb/failure_detector.py78 def set_command_executor(self, command_executor) -> None:CODE
LOWredis/observability/metrics.py33logger = logging.getLogger(__name__)CODE
LOWredis/observability/__init__.py20__all__ = [CODE
LOWredis/observability/providers.py28logger = logging.getLogger(__name__)CODE
LOWredis/http/http_client.py14__all__ = ["HttpClient", "HttpResponse", "HttpError", "DEFAULT_TIMEOUT"]CODE
LOWredis/commands/metadata.py42__all__ = [CODE
LOWredis/commands/__init__.py7__all__ = [CODE
LOWredis/commands/policies.py25__all__ = [CODE
LOWredis/asyncio/keyspace_notifications.py68logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/client.py563 def set_retry(self, retry: Retry) -> None:CODE
LOWredis/asyncio/__init__.py41__all__ = [CODE
LOWredis/asyncio/connection.py796 def set_parser(self, parser_class: Type[BaseParser]) -> None:CODE
LOWredis/asyncio/connection.py1899 def set_retry(self, retry: "Retry") -> None:CODE
LOWredis/asyncio/connection.py2438 def update_connection_kwargs(self, **kwargs: Any) -> None:CODE
LOWredis/asyncio/connection.py2581 def _set_in_maintenance(self, in_maintenance: bool) -> None:CODE
LOWredis/asyncio/connection.py2986 def set_retry(self, retry: "Retry") -> None:CODE
LOWredis/asyncio/connection.py3088 def set_in_maintenance(self, in_maintenance: bool) -> None:CODE
LOWredis/asyncio/cluster.py156logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/cluster.py824 def set_default_node(self, node: "ClusterNode") -> None:CODE
LOWredis/asyncio/cluster.py961 def set_retry(self, retry: Retry) -> None:CODE
LOWredis/asyncio/cluster.py964 def set_response_callback(self, command: str, callback: ResponseCallbackT) -> None:CODE
LOWredis/asyncio/cluster.py1809 def update_active_connections_for_reconnect(self) -> None:CODE
LOWredis/asyncio/cluster.py2553 def set_response_callback(self, command: str, callback: ResponseCallbackT) -> None:CODE
LOWredis/asyncio/cluster.py3658 def set_retry(self, retry: "Retry") -> None:CODE
LOWredis/asyncio/lock.py14logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/maint_notifications.py28logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/multidb/client.py31logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/multidb/client.py152 async def set_active_database(self, database: AsyncDatabase) -> None:CODE
LOWredis/asyncio/multidb/failover.py23 def set_databases(self, databases: Databases) -> None:CODE
LOWredis/asyncio/multidb/failover.py68 def set_databases(self, databases: Databases) -> None:CODE
LOWredis/asyncio/multidb/healthcheck.py49logger = logging.getLogger(__name__)CODE
LOWredis/asyncio/multidb/failure_detector.py18 def set_command_executor(self, command_executor) -> None:CODE
LOWredis/asyncio/multidb/failure_detector.py37 def set_command_executor(self, command_executor) -> None:CODE
LOWredis/_parsers/__init__.py13__all__ = [CODE
LOWredis/_parsers/commands.py36__all__ = [CODE
LOWredis/_parsers/base.py72logger = logging.getLogger(__name__)CODE
LOWtests/test_scenario/test_active_active.py20logger = logging.getLogger(__name__)CODE
LOWtests/test_asyncio/test_scenario/test_active_active.py21logger = logging.getLogger(__name__)CODE
Docstring Block Structure10 hits · 50 pts
SeverityFileLineSnippetContext
HIGHredis/keyspace_notifications.py670 Create a keyevent pattern for subscribing to all event types. This is equivalent to KeyeventChannel("*STRING
HIGHredis/keyspace_notifications.py936 Determine the type of a Redis keyspace notification channel. Args: channel: The channel name to check STRING
HIGHredis/keyspace_notifications.py1475 Start a background thread that polls for notifications and triggers handlers. This method spawns a thrSTRING
HIGHredis/background.py118 Runs a coroutine synchronously and returns its result. Uses the shared health check event loop to ensurSTRING
HIGHredis/commands/helpers.py188 Checks that at most one of the values in the iterable is truthy. Args: iterable: An iterable of valuesSTRING
HIGHredis/commands/json/commands.py29Convert a string or FPHAType instance to a validated FPHAType. Args: value: An ``FPHAType`` member STRING
HIGHredis/_parsers/commands.py446 Determines whether a given command or subcommand is considered "keyless". A keyless command does not operate oSTRING
HIGHredis/_parsers/commands.py571 Traverse a parsed ``COMMAND`` reply, resolving the policies of every command, and build one record per command STRING
HIGHredis/_parsers/commands.py677 Retrieve and process the command policies for all commands and subcommands. This function traverses through coSTRING
HIGHredis/_parsers/commands.py789 Retrieve and process the metadata records cache for all commands and subcommands. This function traverses throSTRING
Structural Annotation Overuse30 hits · 48 pts
SeverityFileLineSnippetContext
LOW…int_notifications/test_maint_notifications_handling.py1791 # Step 2: Run command that will receive and handle MIGRATED notificationCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1800 # Step 3: Validate that MIGRATED notification was processed but MOVING settings remainCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1059 # Step 4: Validate timeout was updated to relaxed value after MIGRATINGCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1080 # Step 6: Validate socket timeout is still relaxed during commands 3-4COMMENT
LOW…int_notifications/test_maint_notifications_handling.py1095 # Step 8: Validate socket timeout is reversed back to original after MIGRATEDCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1257 # Step 4: Validate timeout was updated to relaxed value after MIGRATINGCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1278 # Step 6: Validate socket timeout is still relaxed during commands 3-4COMMENT
LOW…int_notifications/test_maint_notifications_handling.py1293 # Step 8: Validate socket timeout is reversed back to original after FAILED_OVERCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1767 # Step 1: Run command that will receive and handle MOVING notificationCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1817 # Step 4: Create new connections after MIGRATED to verify they still use MOVING settingsCOMMENT
LOWtests/test_observability/test_recorder.py1495 # Step 1: IDLE +1 (creation)COMMENT
LOWtests/test_observability/test_recorder.py1499 # Step 2: IDLE -1, USED +1 (acquire)COMMENT
LOWtests/test_observability/test_recorder.py1505 # Step 3: USED -1, IDLE +1 (release)COMMENT
LOWtests/test_observability/test_recorder.py1511 # Step 4: IDLE -1 (disconnect)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1113 # Step 1: IDLE +1 (creation)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1117 # Step 2: IDLE -1, USED +1 (acquire)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1123 # Step 3: USED -1, IDLE +1 (release)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1129 # Step 4: IDLE -1 (disconnect)COMMENT
LOW.agents/sync_async_type_hints_overload_guide.md19### Step 1: Check Official Redis DocumentationCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md26### Step 2: Check Local Response CallbacksCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md51### Step 3: Check Test AssertionsCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md75### Step 1: Add `@overload` SignaturesCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md82### Step 2: Mirror the Input SignatureCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md88### Step 3: Keep Original ImplementationCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md96### Step 4: Run Type CheckerCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md114## Step 1: Research the CommandCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md121## Step 2: Define the Function SignatureCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md140## Step 3: Implement the Overload PatternCOMMENT
LOW.agents/sync_async_type_hints_overload_guide.md177## Step 4: Register Response Callback (if needed)COMMENT
LOW.agents/sync_async_type_hints_overload_guide.md191## Step 5: Add TestsCOMMENT
AI Slop Vocabulary20 hits · 40 pts
SeverityFileLineSnippetContext
LOWredis/cluster.py1564 # so we can just return a random slotCOMMENT
LOWredis/cluster.py1572 # can be run on any node so we can just return a random slotCOMMENT
LOWredis/maint_notifications.py874 # just returnCOMMENT
LOWredis/asyncio/cluster.py1019 # so we can just return a random slotCOMMENT
LOWredis/asyncio/cluster.py1026 # can be run on any node so we can just return a random slotCOMMENT
LOWredis/asyncio/maint_notifications.py139 # just returnCOMMENT
LOWredis/_parsers/hiredis.py205 # blocking error, simply return False indicating thatCOMMENT
LOWredis/_parsers/resp3.py84 # necessary, so just return the exception instance here.COMMENT
LOWredis/_parsers/resp3.py220 # necessary, so just return the exception instance here.COMMENT
LOWredis/_parsers/socket.py81 # blocking error, simply return False indicating thatCOMMENT
LOWredis/_parsers/helpers.py341 # if for some reason the value can't be coerced, just useCOMMENT
LOWredis/_parsers/resp2.py49 # necessary, so just return the exception instance here.COMMENT
LOWredis/_parsers/resp2.py113 # necessary, so just return the exception instance here.COMMENT
MEDIUMtests/test_search.py936 # so pin only that here and let the harness supply the protocol xCOMMENT
LOWtests/test_ssl.py399 # Don't actually wrap the socket, just return the original socketCOMMENT
MEDIUMtests/test_asyncio/test_search.py978 # so pin only that here and let the harness supply the protocol xCOMMENT
MEDIUMtests/test_asyncio/test_cwe_404.py97 # ignore errors on close pertaining to no event loop. Don't wantCOMMENT
MEDIUMbenchmarks/otel_benchmark.py883 # Create comprehensive generator with baseline redis moduleCOMMENT
MEDIUMbenchmarks/otel_benchmark.py939 # Create async comprehensive generator with baseline redis moduleCOMMENT
MEDIUMbenchmarks/base.py16 # eventually make this more robust and take optional args fromCOMMENT
Verbosity Indicators20 hits · 30 pts
SeverityFileLineSnippetContext
LOWredis/multidb/config.py74 grace_period (float): Grace period after which we need to check if the circuit could be closed again.STRING
LOWredis/asyncio/multidb/config.py76 grace_period (float): Grace period after which we need to check if the circuit could be closed again.STRING
LOW…int_notifications/test_maint_notifications_handling.py1791 # Step 2: Run command that will receive and handle MIGRATED notificationCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1800 # Step 3: Validate that MIGRATED notification was processed but MOVING settings remainCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1059 # Step 4: Validate timeout was updated to relaxed value after MIGRATINGCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1080 # Step 6: Validate socket timeout is still relaxed during commands 3-4COMMENT
LOW…int_notifications/test_maint_notifications_handling.py1095 # Step 8: Validate socket timeout is reversed back to original after MIGRATEDCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1257 # Step 4: Validate timeout was updated to relaxed value after MIGRATINGCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1278 # Step 6: Validate socket timeout is still relaxed during commands 3-4COMMENT
LOW…int_notifications/test_maint_notifications_handling.py1293 # Step 8: Validate socket timeout is reversed back to original after FAILED_OVERCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1767 # Step 1: Run command that will receive and handle MOVING notificationCOMMENT
LOW…int_notifications/test_maint_notifications_handling.py1817 # Step 4: Create new connections after MIGRATED to verify they still use MOVING settingsCOMMENT
LOWtests/test_observability/test_recorder.py1495 # Step 1: IDLE +1 (creation)COMMENT
LOWtests/test_observability/test_recorder.py1499 # Step 2: IDLE -1, USED +1 (acquire)COMMENT
LOWtests/test_observability/test_recorder.py1505 # Step 3: USED -1, IDLE +1 (release)COMMENT
LOWtests/test_observability/test_recorder.py1511 # Step 4: IDLE -1 (disconnect)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1113 # Step 1: IDLE +1 (creation)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1117 # Step 2: IDLE -1, USED +1 (acquire)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1123 # Step 3: USED -1, IDLE +1 (release)COMMENT
LOWtests/test_asyncio/test_observability/test_recorder.py1129 # Step 4: IDLE -1 (disconnect)COMMENT
Hallucination Indicators2 hits · 20 pts
SeverityFileLineSnippetContext
CRITICALredis/multidb/event.py74 for node in event.old_database.client.nodes_manager.nodes_cache.values():CODE
CRITICALtests/test_asyncio/test_scenario/conftest.py289 await client.command_executor.active_database.client.connection_pool.disconnect()CODE
Modern AI Meta-Vocabulary5 hits · 15 pts
SeverityFileLineSnippetContext
MEDIUMredis/client.py978 # HIMPORT orchestration. The registry lives on the shared HImportRegistry; theCOMMENT
MEDIUMredis/cluster.py1467 # HIMPORT orchestration. PREPARE/DISCARD/DISCARDALL mutate the one sharedCOMMENT
MEDIUMredis/commands/core.py10761 # DISCARD / DISCARDALL wire mappings; the client-side orchestration around themCOMMENT
MEDIUMredis/asyncio/client.py1013 # HIMPORT orchestration (async mirror of redis.client.Redis). SeeCOMMENT
MEDIUMredis/asyncio/cluster.py919 # HIMPORT orchestration (async mirror of redis.cluster.RedisCluster). The oneCOMMENT
Cross-Language Confusion2 hits · 12 pts
SeverityFileLineSnippetContext
HIGHdoctests/dt_json.py72print(res12) # >>> ['["Deimos", { "crashes": 0 }, null]']CODE
HIGH…int_notifications/test_maint_notifications_handling.py249 # Format: >4\r\n$6\r\nMOVING\r\n:1\r\n:1\r\n+null\r\n (4 elements: MOVING, id, ttl, null)COMMENT
Slop Phrases5 hits · 7 pts
SeverityFileLineSnippetContext
LOWredis/client.py1881 # make sure to reset the connection state in the event that we wereCOMMENT
LOWredis/cluster.py5111 # make sure to reset the connection state in the event that we wereCOMMENT
LOWredis/asyncio/client.py1853 # make sure to reset the connection state in the event that we wereCOMMENT
LOWredis/asyncio/cluster.py3516 # make sure to reset the connection state in the event that weCOMMENT
LOWredis/_parsers/socket.py102 length = length + 2 # make sure to read the \r\n terminatorCODE
Fake / Example Data2 hits · 2 pts
SeverityFileLineSnippetContext
LOWtests/test_search.py1001 client.hset("doc2", mapping={"f1": "very important", "f2": "lorem ipsum"})CODE
LOWtests/test_asyncio/test_search.py1092 "doc2", mapping={"f1": "very important", "f2": "lorem ipsum"}CODE
Overly Generic Function Names3 hits · 2 pts
SeverityFileLineSnippetContext
LOWtests/test_commands.py8489 def helper():CODE
LOWtests/test_asyncio/test_commands.py6430 async def helper():CODE
LOWdocs/examples/opentelemetry/main.py31def handle_request(client):CODE