A template for PostgreSQL High Availability with Etcd, Consul, ZooKeeper, or Kubernetes
This report presents the forensic synthetic code analysis of patroni/patroni, a Python project with 8,642 GitHub stars. SynthScan v2.0 examined 55,226 lines of code across 158 source files, recording 1037 pattern matches distributed across 13 syntactic categories. The overall adjusted score of 21.8 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).
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.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 1037 distinct pattern matches across 13 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/validator.py | 185 | def comma_separated_host_port(string: str) -> bool: | CODE |
| LOW | patroni/validator.py | 197 | def validate_host_port_listen(host_port: str) -> bool: | CODE |
| LOW | patroni/validator.py | 210 | def validate_host_port_listen_multiple_hosts(host_port: str) -> bool: | CODE |
| LOW | patroni/validator.py | 975 | def validate_synchronous_mode(value: Any) -> None: | CODE |
| LOW | patroni/ha.py | 317 | def quorum_commit_mode_is_active(self) -> bool: | CODE |
| LOW | patroni/ha.py | 324 | def _get_failover_action_name(self) -> str: | CODE |
| LOW | patroni/ha.py | 600 | def _handle_rewind_or_reinitialize(self) -> Optional[str]: | CODE |
| LOW | patroni/ha.py | 832 | def _maybe_enable_synchronous_mode(self) -> Optional[SyncState]: | CODE |
| LOW | patroni/ha.py | 850 | def disable_synchronous_replication(self) -> None: | CODE |
| LOW | patroni/ha.py | 865 | def _handle_synchronous_strict_mode(self, dcs_state: SyncState, replication_state: Any) -> bool: | CODE |
| LOW | patroni/ha.py | 915 | def _process_quorum_replication(self) -> None: | CODE |
| LOW | patroni/ha.py | 976 | def _process_multisync_replication(self) -> None: | CODE |
| LOW | patroni/ha.py | 1050 | def _process_multisync_prepromote(self) -> bool: | CODE |
| LOW | patroni/ha.py | 1081 | def _process_quorum_prepromote(self) -> None: | CODE |
| LOW | patroni/ha.py | 1101 | def process_sync_replication_prepromote(self) -> bool: | CODE |
| LOW | patroni/ha.py | 1184 | def enforce_follow_remote_member(self, message: str) -> str: | CODE |
| LOW | patroni/ha.py | 1507 | def manual_failover_process_no_leader(self) -> Optional[bool]: | CODE |
| LOW | patroni/ha.py | 1657 | def release_leader_key_voluntarily(self, last_lsn: Optional[int] = None) -> None: | CODE |
| LOW | patroni/ha.py | 1776 | def should_run_scheduled_action(self, action_name: str, scheduled_at: Optional[datetime.datetime], | CODE |
| LOW | patroni/ha.py | 1811 | def process_manual_failover_from_leader(self) -> Optional[str]: | CODE |
| LOW | patroni/ha.py | 1851 | def process_unhealthy_cluster(self) -> str: | CODE |
| LOW | patroni/ha.py | 1964 | def evaluate_scheduled_restart(self) -> Optional[str]: | CODE |
| LOW | patroni/ha.py | 2118 | def handle_long_action_in_progress(self) -> str: | CODE |
| LOW⚡ | patroni/config.py | 273 | def __get_and_maybe_adjust_int_value(self, config: Dict[str, Any], param: str, min_value: int) -> int: | CODE |
| LOW | patroni/config.py | 293 | def _validate_and_adjust_timeouts(self, config: Dict[str, Any]) -> None: | CODE |
| LOW | patroni/config.py | 334 | def set_dynamic_configuration(self, configuration: Union[ClusterConfig, Dict[str, Any]]) -> bool: | CODE |
| LOW | patroni/config.py | 360 | def reload_local_configuration(self) -> Optional[bool]: | CODE |
| LOW | patroni/config.py | 384 | def _process_postgresql_parameters(parameters: Any, is_local: bool = False) -> Dict[str, Any]: | CODE |
| LOW | patroni/config.py | 435 | def _safe_copy_dynamic_configuration(self, dynamic_configuration: Dict[str, Any]) -> Dict[str, Any]: | CODE |
| LOW | patroni/config.py | 481 | def _build_environment_configuration() -> Dict[str, Any]: | CODE |
| LOW | patroni/config.py | 712 | def _build_effective_configuration(self, dynamic_configuration: Dict[str, Any], | CODE |
| LOW | patroni/config.py | 831 | def build_effective_postgresql_configuration(self, role: PostgresqlRole) -> Dict[str, Any]: | CODE |
| LOW | patroni/config.py | 878 | def _validate_contradictory_tags(self) -> None: | CODE |
| LOW | patroni/log.py | 130 | def _try_to_report_lost_records(self) -> None: | CODE |
| LOW | patroni/global_config.py | 39 | def _cluster_has_valid_config(cluster: Optional['Cluster']) -> bool: | CODE |
| LOW | patroni/global_config.py | 120 | def is_synchronous_mode_strict(self) -> bool: | CODE |
| LOW | patroni/global_config.py | 124 | def get_standby_cluster_config(self) -> Any: | CODE |
| LOW | patroni/file_perm.py | 76 | def set_permissions_from_data_directory(self, data_dir: str) -> None: | CODE |
| LOW | patroni/ctl.py | 586 | def get_all_members_leader_first(cluster: Cluster) -> Iterator[Member]: | CODE |
| LOW | patroni/ctl.py | 1255 | def _do_failover_or_switchover(action: str, cluster_name: str, group: Optional[int], candidate: Optional[str], | CODE |
| LOW | patroni/ctl.py | 1833 | def wait_until_pause_is_applied(dcs: AbstractDCS, paused: bool, old_cluster: Cluster) -> None: | CODE |
| LOW | patroni/ctl.py | 2019 | def format_config_for_editing(data: Any, default_flow_style: bool = False) -> str: | CODE |
| LOW | patroni/quorum.py | 255 | def __handle_non_steady_cases(self) -> Iterator[Transition]: | CODE |
| LOW | patroni/quorum.py | 375 | def __handle_replication_factor_change(self) -> Iterator[Transition]: | CODE |
| LOW | patroni/api.py | 1904 | def get_certificate_serial_number(self) -> Optional[str]: | CODE |
| LOW | patroni/utils.py | 323 | def convert_int_from_base_unit(base_value: int, base_unit: Optional[str]) -> Optional[str]: | CODE |
| LOW | patroni/utils.py | 367 | def convert_real_from_base_unit(base_value: float, base_unit: Optional[str]) -> Optional[str]: | CODE |
| LOW | patroni/utils.py | 411 | def maybe_convert_from_base_unit(base_value: str, vartype: str, base_unit: Optional[str]) -> str: | CODE |
| LOW | patroni/config_generator.py | 327 | def _get_bin_dir_from_running_instance(self) -> str: | CODE |
| LOW | patroni/config_generator.py | 465 | def _enrich_config_from_running_instance(self) -> None: | CODE |
| LOW | patroni/__main__.py | 117 | def apply_dynamic_configuration(self, cluster: 'Cluster') -> None: | CODE |
| LOW | patroni/postgresql/validator.py | 235 | def _get_postgres_guc_validators(config: Dict[str, Any], parameter: str) -> Tuple[_Transformable, ...]: | CODE |
| LOW | patroni/postgresql/validator.py | 261 | def _read_postgres_gucs_validators_file(file: PathLikeObj) -> Dict[str, Any]: | CODE |
| LOW | patroni/postgresql/validator.py | 280 | def _load_postgres_gucs_validators() -> None: | CODE |
| LOW | patroni/postgresql/validator.py | 413 | def _transform_parameter_value(validators: MutableMapping[str, Tuple[_Transformable, ...]], | CODE |
| LOW | patroni/postgresql/validator.py | 446 | def transform_postgresql_parameter_value(version: int, name: str, value: Any, | CODE |
| LOW | patroni/postgresql/validator.py | 473 | def transform_recovery_parameter_value(version: int, name: str, value: Any, | CODE |
| LOW | patroni/postgresql/bootstrap.py | 33 | def keep_existing_recovery_conf(self) -> bool: | CODE |
| LOW | patroni/postgresql/sync.py | 304 | def _handle_synchronous_standby_names_change(self) -> None: | CODE |
| LOW | patroni/postgresql/sync.py | 336 | def _process_replica_readiness(self, cluster: Cluster, replica_list: _ReplicaList) -> None: | CODE |
| 392 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 145 | except Exception: | CODE |
| MEDIUM | setup.py | 142 | def run(self): | CODE |
| LOW | patroni/validator.py | 237 | except Exception: | CODE |
| LOW | patroni/validator.py | 254 | except Exception: | CODE |
| LOW | patroni/validator.py | 719 | except Exception as e: | CODE |
| MEDIUM | patroni/ha.py | 356 | def acquire_lock(self) -> bool: | CODE |
| LOW | patroni/ha.py | 361 | except Exception: | CODE |
| LOW | patroni/ha.py | 397 | except Exception: | CODE |
| LOW | patroni/ha.py | 403 | except Exception: | CODE |
| LOW | patroni/ha.py | 444 | except Exception as e: | CODE |
| LOW | patroni/ha.py | 509 | except Exception: | CODE |
| LOW | patroni/ha.py | 1257 | except Exception as e: | CODE |
| LOW | patroni/ha.py | 1301 | except Exception as e: | CODE |
| LOW | patroni/ha.py | 1340 | except Exception: | CODE |
| LOW | patroni/ha.py | 1758 | except Exception: | CODE |
| LOW | patroni/ha.py | 2267 | except Exception as exc1: | CODE |
| LOW | patroni/ha.py | 2274 | except Exception as exc2: | CODE |
| LOW | patroni/ha.py | 2493 | except Exception: | CODE |
| LOW | patroni/raft_controller.py | 23 | except Exception: | CODE |
| MEDIUM | patroni/raft_controller.py | 20 | def _run_cycle(self) -> None: | CODE |
| LOW⚡ | patroni/config.py | 260 | except Exception: | CODE |
| LOW⚡ | patroni/config.py | 265 | except Exception: | CODE |
| LOW⚡ | patroni/config.py | 270 | except Exception: | CODE |
| LOW | patroni/config.py | 239 | except Exception: | CODE |
| LOW | patroni/config.py | 356 | except Exception: | CODE |
| LOW | patroni/config.py | 380 | except Exception: | CODE |
| LOW | patroni/config.py | 605 | except Exception: | CODE |
| LOW | patroni/config.py | 633 | except Exception: | CODE |
| LOW | patroni/log.py | 143 | except Exception: | CODE |
| LOW | patroni/log.py | 158 | except Exception: | CODE |
| LOW | patroni/log.py | 413 | except Exception as e: | CODE |
| LOW | patroni/log.py | 506 | except Exception: | CODE |
| LOW | patroni/file_perm.py | 55 | except Exception as e: | CODE |
| LOW | patroni/file_perm.py | 87 | except Exception as e: | CODE |
| LOW | patroni/ctl.py | 200 | except Exception as e: | CODE |
| LOW | patroni/ctl.py | 1406 | except Exception: | CODE |
| LOW | patroni/ctl.py | 1824 | except Exception as err: | CODE |
| LOW | patroni/ctl.py | 1885 | except Exception as err: | CODE |
| LOW | patroni/ctl.py | 2280 | except Exception as e: | CODE |
| LOW | patroni/ctl.py | 2375 | except Exception as err: | CODE |
| LOW | patroni/psycopg.py | 179 | except Exception: | CODE |
| LOW | patroni/api.py | 803 | except Exception: | CODE |
| LOW | patroni/api.py | 1035 | except Exception: | CODE |
| LOW | patroni/api.py | 1154 | except Exception as e: | CODE |
| LOW | patroni/api.py | 1526 | except Exception as e: | CODE |
| LOW | patroni/api.py | 1648 | except Exception as e: | CODE |
| LOW | patroni/api.py | 1670 | except Exception as e: | CODE |
| LOW | patroni/api.py | 1785 | except Exception: | CODE |
| LOW | patroni/api.py | 1900 | except Exception as e: | CODE |
| LOW | patroni/api.py | 1944 | except Exception as e: | CODE |
| LOW | patroni/async_executor.py | 169 | except Exception: | CODE |
| LOW | patroni/config_generator.py | 66 | except Exception as err: | CODE |
| LOW | patroni/config_generator.py | 526 | except Exception as e: | CODE |
| LOW | patroni/__main__.py | 68 | except Exception as e: | CODE |
| LOW | patroni/__main__.py | 156 | except Exception: | CODE |
| LOW | patroni/__main__.py | 195 | except Exception: | CODE |
| LOW | patroni/__main__.py | 267 | except Exception: | CODE |
| LOW | patroni/__main__.py | 271 | except Exception: | CODE |
| LOW | patroni/daemon.py | 237 | except Exception as e: | CODE |
| LOW | patroni/postgresql/validator.py | 230 | except Exception as exc: | CODE |
| 175 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH⚡ | features/environment.py | 635 | if subprocess.call([docker, 'info'], stdout=null, stderr=null) != 0: | CODE |
| HIGH⚡ | features/environment.py | 640 | if subprocess.call([docker, 'info'], stdout=null, stderr=null) != 0: | CODE |
| HIGH | features/environment.py | 1109 | '-out', context.certfile], stdout=null, stderr=null) | CODE |
| HIGH⚡ | features/steps/citus.py | 70 | context.pctl.query(name, 'CREATE TABLE public.d(id int not null)') | CODE |
| HIGH | tests/test_consul.py | 47 | 'ModifyIndex': 6429, 'Value': b'{"leader": "leader", "sync_standby": null}'}, | CODE |
| HIGH⚡ | tests/test_citus.py | 254 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 265 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 276 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 286 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 326 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 336 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 346 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 356 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 365 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 374 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 383 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH⚡ | tests/test_citus.py | 393 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH | tests/test_citus.py | 229 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH | tests/test_citus.py | 242 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH | tests/test_citus.py | 297 | self.assertTrue(new.equals(expected, True)) | CODE |
| HIGH | tests/test_citus.py | 312 | self.assertTrue(new.equals(expected, True)) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 174 | CODE | |
| LOW | patroni/validator.py | 110 | CODE | |
| LOW | patroni/validator.py | 270 | CODE | |
| LOW | patroni/validator.py | 527 | CODE | |
| LOW | patroni/validator.py | 683 | CODE | |
| LOW | patroni/validator.py | 757 | CODE | |
| LOW | patroni/validator.py | 816 | CODE | |
| LOW | patroni/ha.py | 448 | CODE | |
| LOW | patroni/ha.py | 754 | CODE | |
| LOW | patroni/ha.py | 915 | CODE | |
| LOW | patroni/ha.py | 1119 | CODE | |
| LOW | patroni/ha.py | 1163 | CODE | |
| LOW | patroni/ha.py | 1188 | CODE | |
| LOW | patroni/ha.py | 1367 | CODE | |
| LOW | patroni/ha.py | 1465 | CODE | |
| LOW | patroni/ha.py | 1507 | CODE | |
| LOW | patroni/ha.py | 1776 | CODE | |
| LOW | patroni/ha.py | 1811 | CODE | |
| LOW | patroni/ha.py | 1851 | CODE | |
| LOW | patroni/ha.py | 1911 | CODE | |
| LOW | patroni/ha.py | 2118 | CODE | |
| LOW | patroni/ha.py | 2259 | CODE | |
| LOW | patroni/ha.py | 2497 | CODE | |
| LOW | patroni/config.py | 242 | CODE | |
| LOW | patroni/config.py | 384 | CODE | |
| LOW | patroni/config.py | 435 | CODE | |
| LOW | patroni/config.py | 481 | CODE | |
| LOW | patroni/config.py | 712 | CODE | |
| LOW | patroni/dynamic_loader.py | 73 | CODE | |
| LOW | patroni/log.py | 342 | CODE | |
| LOW | patroni/log.py | 441 | CODE | |
| LOW | patroni/log.py | 509 | CODE | |
| LOW | patroni/ctl.py | 422 | CODE | |
| LOW | patroni/ctl.py | 897 | CODE | |
| LOW | patroni/ctl.py | 1112 | CODE | |
| LOW | patroni/ctl.py | 1565 | CODE | |
| LOW | patroni/ctl.py | 1788 | CODE | |
| LOW | patroni/ctl.py | 2251 | CODE | |
| LOW | patroni/api.py | 247 | CODE | |
| LOW | patroni/api.py | 950 | CODE | |
| LOW | patroni/api.py | 1124 | CODE | |
| LOW | patroni/api.py | 1651 | CODE | |
| LOW | patroni/api.py | 1931 | CODE | |
| LOW | patroni/utils.py | 122 | CODE | |
| LOW | patroni/utils.py | 913 | CODE | |
| LOW | patroni/utils.py | 1286 | CODE | |
| LOW | patroni/config_generator.py | 184 | CODE | |
| LOW | patroni/config_generator.py | 370 | CODE | |
| LOW | patroni/__main__.py | 285 | CODE | |
| LOW | patroni/__main__.py | 388 | CODE | |
| LOW | patroni/__main__.py | 417 | CODE | |
| LOW | patroni/postgresql/bootstrap.py | 157 | CODE | |
| LOW | patroni/postgresql/bootstrap.py | 253 | CODE | |
| LOW | patroni/postgresql/bootstrap.py | 372 | CODE | |
| LOW | patroni/postgresql/sync.py | 63 | CODE | |
| LOW | patroni/postgresql/sync.py | 336 | CODE | |
| LOW | patroni/postgresql/sync.py | 361 | CODE | |
| LOW | patroni/postgresql/callback_executor.py | 69 | CODE | |
| LOW | patroni/postgresql/config.py | 215 | CODE | |
| LOW | patroni/postgresql/config.py | 519 | CODE | |
| 71 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/ha.py | 27 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/ha.py | 120 | def update_slots(self, slots: Dict[str, int]) -> None: | CODE |
| LOW | patroni/ha.py | 207 | def set_is_active(self, value: float) -> None: | CODE |
| LOW | patroni/ha.py | 299 | def set_is_leader(self, value: bool) -> None: | CODE |
| LOW | patroni/ha.py | 1163 | def update_cluster_history(self) -> None: | CODE |
| LOW | patroni/ha.py | 2252 | def set_start_timeout(self, value: Optional[int]) -> None: | CODE |
| LOW | patroni/raft_controller.py | 8 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/config.py | 25 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/config.py | 534 | def _set_section_values(section: str, params: List[str]) -> None: | CODE |
| LOW | patroni/dynamic_loader.py | 15 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/log.py | 37 | def set_log_file_mode(self, mode: Optional[int]) -> None: | CODE |
| LOW | patroni/log.py | 252 | def update_loggers(self, config: Dict[str, Any]) -> None: | CODE |
| LOW | patroni/file_perm.py | 10 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/file_perm.py | 76 | def set_permissions_from_data_directory(self, data_dir: str) -> None: | CODE |
| LOW | patroni/ctl.py | 165 | def _set_hline(self, value: str) -> None: | CODE |
| LOW | patroni/psycopg.py | 13 | __all__ = ['connect', 'parse_conninfo', 'quote_ident', 'quote_literal', | CODE |
| LOW | patroni/quorum.py | 9 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/api.py | 37 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/api.py | 1596 | def _set_fd_cloexec(fd: socket.socket) -> None: | CODE |
| LOW | patroni/utils.py | 41 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/utils.py | 703 | def update_delay(self) -> None: | CODE |
| LOW | patroni/async_executor.py | 11 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/config_generator.py | 370 | def _set_pg_params(self, cur: Union['cursor', 'Cursor[Any]']) -> None: | CODE |
| LOW | patroni/config_generator.py | 413 | def _set_su_params(self) -> None: | CODE |
| LOW | patroni/config_generator.py | 436 | def _set_conf_files(self) -> None: | CODE |
| LOW | patroni/__main__.py | 26 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/daemon.py | 45 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/validator.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/bootstrap.py | 19 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/sync.py | 17 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/sync.py | 415 | def set_synchronous_standby_names(self, sync: Collection[str], num: Optional[int] = None) -> None: | CODE |
| LOW | patroni/postgresql/misc.py | 10 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/callback_executor.py | 11 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/config.py | 30 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/config.py | 492 | def set_file_permissions(self, filename: str) -> None: | CODE |
| LOW | patroni/postgresql/slots.py | 29 | logger = logging.getLogger(__name__) | CODE |
| LOW⚡ | patroni/postgresql/__init__.py | 468 | def set_enforce_hot_standby_feedback(self, value: bool) -> None: | CODE |
| LOW⚡ | patroni/postgresql/__init__.py | 717 | def set_role(self, value: PostgresqlRole) -> None: | CODE |
| LOW⚡ | patroni/postgresql/__init__.py | 726 | def set_state(self, value: PostgresqlState) -> None: | CODE |
| LOW | patroni/postgresql/__init__.py | 43 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/__init__.py | 355 | def set_pending_restart_reason(self, diff_dict: CaseInsensitiveDict) -> None: | CODE |
| LOW | patroni/postgresql/rewind.py | 21 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/connection.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/postmaster.py | 26 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/cancellable.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/available_parameters/__init__.py | 6 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/mpp/citus.py | 20 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/postgresql/mpp/citus.py | 523 | def update_node(self, groupid: int, node: PgDistNode, cooldown: float = 10000) -> None: | CODE |
| LOW | patroni/postgresql/mpp/citus.py | 534 | def update_group(self, task: PgDistTask, transaction: bool) -> None: | CODE |
| LOW | patroni/watchdog/__init__.py | 3 | __all__ = ['WatchdogError', 'Watchdog'] | CODE |
| LOW | patroni/watchdog/linux.py | 212 | def set_timeout(self, timeout: int) -> None: | CODE |
| LOW | patroni/watchdog/linux.py | 237 | def set_timeout(self, timeout: int) -> None: | CODE |
| LOW | patroni/watchdog/base.py | 12 | __all__ = ['WatchdogError', 'Watchdog'] | CODE |
| LOW | patroni/watchdog/base.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/watchdog/base.py | 291 | def set_timeout(self, timeout: int) -> None: | CODE |
| LOW | patroni/scripts/wale_restore.py | 39 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/scripts/aws.py | 16 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/scripts/barman/utils.py | 67 | def set_up_logging(log_file: Optional[str] = None) -> None: | CODE |
| LOW | patroni/dcs/exhibitor.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | patroni/dcs/etcd3.py | 30 | logger = logging.getLogger(__name__) | CODE |
| 26 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL⚡ | tests/test_ha.py | 280 | self.ha.cluster.config.data.update({'standby_cluster': {'port': 5432}}) | STRING |
| CRITICAL⚡ | tests/test_ha.py | 1422 | self.ha.cluster.config.data.update({'synchronous_mode': True, 'primary_start_timeout': 0}) | STRING |
| CRITICAL⚡ | tests/test_ha.py | 1431 | self.ha.cluster.config.data.update({'primary_stop_timeout': 30}) | STRING |
| CRITICAL⚡ | tests/test_ha.py | 1769 | self.ha.cluster.config.data.clear() | STRING |
| CRITICAL | tests/test_ha.py | 339 | self.ha.cluster.config.data.update({'maximum_lag_on_failover': 10}) | STRING |
| CRITICAL | tests/test_ha.py | 372 | self.ha.cluster.leader.member.data.update(version='2.0.2', role=PostgresqlRole.PRIMARY) | STRING |
| CRITICAL | tests/test_ha.py | 512 | self.ha.cluster.config.data.update({'slots': {'l': {'database': 'a', 'plugin': 'b'}}}) | STRING |
| CRITICAL | tests/test_ha.py | 517 | self.ha.cluster.config.data.update({'postgresql': {'use_slots': False}}) | STRING |
| CRITICAL | tests/test_ha.py | 854 | self.ha.cluster.config.data.update({'maximum_lag_on_failover': 5}) | STRING |
| CRITICAL | tests/test_ha.py | 897 | self.ha.cluster.config.data.update({'maximum_lag_on_failover': 5}) | STRING |
| CRITICAL | tests/test_ha.py | 1041 | self.ha.cluster.config.data.update({'maximum_lag_on_failover': 5}) | STRING |
| CRITICAL | tests/test_ha.py | 1190 | self.ha.cluster.config.data.update({'maximum_lag_on_failover': 5}) | STRING |
| CRITICAL | tests/test_ha.py | 1460 | self.ha.cluster.config.data.update({'standby_cluster': {'port': 5432}}) | STRING |
| CRITICAL | tests/test_ha.py | 1494 | self.ha.cluster.config.data.update({'standby_cluster': {'restore_command': 'foo', 'port': None}}) | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | patroni/dcs/etcd3.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/zookeeper.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/__init__.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/etcd.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/consul.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/kubernetes.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/raft.py | 0 | load and build the :class:`cluster` object from dcs, which represents a single postgresql cluster. :param path: the path | STRING |
| HIGH | patroni/dcs/etcd3.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/zookeeper.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/__init__.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/etcd.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/consul.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/kubernetes.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| HIGH | patroni/dcs/raft.py | 0 | load and build all postgresql clusters from a single mpp cluster. :param path: the path in dcs where to load cluster(s) | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/dynamic_loader.py | 13 | CODE | |
| LOW | patroni/global_config.py | 17 | CODE | |
| LOW | patroni/ctl.py | 51 | CODE | |
| LOW | patroni/psycopg.py | 10 | CODE | |
| LOW | patroni/psycopg.py | 11 | CODE | |
| LOW | patroni/psycopg.py | 11 | CODE | |
| LOW | patroni/psycopg.py | 23 | CODE | |
| LOW | patroni/psycopg.py | 23 | CODE | |
| LOW | patroni/psycopg.py | 23 | CODE | |
| LOW | patroni/psycopg.py | 23 | CODE | |
| LOW | patroni/psycopg.py | 75 | CODE | |
| LOW | patroni/psycopg.py | 75 | CODE | |
| LOW | patroni/psycopg.py | 75 | CODE | |
| LOW | patroni/psycopg.py | 75 | CODE | |
| LOW | patroni/utils.py | 37 | CODE | |
| LOW | patroni/config_generator.py | 16 | CODE | |
| LOW | patroni/__main__.py | 23 | CODE | |
| LOW | patroni/__main__.py | 24 | CODE | |
| LOW | patroni/postgresql/bootstrap.py | 17 | CODE | |
| LOW | patroni/postgresql/sync.py | 15 | CODE | |
| LOW | patroni/postgresql/config.py | 28 | CODE | |
| LOW | patroni/postgresql/slots.py | 24 | CODE | |
| LOW | patroni/postgresql/slots.py | 25 | CODE | |
| LOW | patroni/postgresql/slots.py | 27 | CODE | |
| LOW | patroni/postgresql/__init__.py | 40 | CODE | |
| LOW | patroni/postgresql/__init__.py | 40 | CODE | |
| LOW | patroni/postgresql/__init__.py | 41 | CODE | |
| LOW | patroni/postgresql/__init__.py | 41 | CODE | |
| LOW | patroni/postgresql/connection.py | 8 | CODE | |
| LOW | patroni/postgresql/connection.py | 8 | CODE | |
| LOW | patroni/postgresql/mpp/__init__.py | 15 | CODE | |
| LOW | patroni/postgresql/mpp/__init__.py | 16 | CODE | |
| LOW | patroni/postgresql/mpp/citus.py | 16 | CODE | |
| LOW | patroni/watchdog/__init__.py | 1 | CODE | |
| LOW | patroni/watchdog/__init__.py | 1 | CODE | |
| LOW | patroni/scripts/barman/config_switch.py | 27 | CODE | |
| LOW | patroni/scripts/barman/recover.py | 27 | CODE | |
| LOW | patroni/dcs/zookeeper.py | 22 | CODE | |
| LOW | patroni/dcs/__init__.py | 27 | CODE | |
| LOW | patroni/dcs/__init__.py | 28 | CODE | |
| LOW | patroni/dcs/__init__.py | 30 | CODE | |
| LOW | patroni/dcs/etcd.py | 33 | CODE | |
| LOW | patroni/dcs/consul.py | 27 | CODE | |
| LOW | patroni/dcs/kubernetes.py | 33 | CODE | |
| LOW | patroni/dcs/raft.py | 33 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | postgres1.yml | 1 | scope: batman | COMMENT |
| LOW | postgres1.yml | 21 | #citus: | COMMENT |
| LOW | postgres1.yml | 61 | # For kerberos gss based connectivity (discard @.*$) | COMMENT |
| LOW | postgres0.yml | 1 | scope: batman | COMMENT |
| LOW | postgres0.yml | 21 | #citus: | COMMENT |
| LOW | postgres0.yml | 41 | # self_addr: 127.0.0.1:2222 | COMMENT |
| LOW | postgres0.yml | 61 | #host: 127.0.0.1 | COMMENT |
| LOW | postgres0.yml | 81 | # max_replication_slots: 10 | COMMENT |
| LOW | postgres0.yml | 121 | parameters: | COMMENT |
| LOW | docker-compose-citus.yml | 1 | # docker compose file for running a Citus cluster | COMMENT |
| LOW | postgres2.yml | 21 | #citus: | COMMENT |
| LOW | postgres2.yml | 61 | # For kerberos gss based connectivity (discard @.*$) | COMMENT |
| LOW | patroni/api.py | 81 | # A hacky way to have decorators that work with and without parameters. | COMMENT |
| LOW | patroni/postgresql/config.py | 341 | 'old_value': (maybe_convert_from_base_unit(str_value(old_value), vartype, unit) | COMMENT |
| LOW | patroni/postgresql/postmaster.py | 301 | # in python. It will start postgres, wait for port to be open and wait until postgres will start | COMMENT |
| LOW | patroni/scripts/wale_restore.py | 1 | #!/usr/bin/env python | COMMENT |
| LOW | docs/conf.py | 1 | #!/usr/bin/env python3 | COMMENT |
| LOW | docs/conf.py | 81 | author = 'Patroni Contributors' | COMMENT |
| LOW | docs/conf.py | 141 | COMMENT | |
| LOW | docs/conf.py | 161 | COMMENT | |
| LOW | kubernetes/citus_k8s.yaml | 241 | - name: pgdata | COMMENT |
| LOW | kubernetes/patroni_k8s.yaml | 101 | - name: pgdata | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/validator.py | 151 | # Check if "socket.IF_INET" or "socket.IF_INET6" is being used and instantiate a socket with the identified | COMMENT |
| LOW | patroni/ha.py | 2216 | # Check if we are in startup, when paused defer to main loop for manual failovers. | COMMENT |
| LOW | patroni/ha.py | 2315 | # Check if we tried to recover from postgres crash and failed | COMMENT |
| LOW | patroni/postgresql/config.py | 1250 | # Check if any parameter was set back to the current pg_settings value | COMMENT |
| LOW | patroni/postgresql/mpp/citus.py | 657 | # Add the task to the list if Worker node state is different from the cached `pg_dist_group` | COMMENT |
| LOW | tests/test_patroni.py | 316 | # Set role to REPLICA | COMMENT |
| LOW | tests/test_patroni.py | 338 | # Set role to REPLICA and mark it as already processed | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | patroni/api.py | 1983 | # Define the Server header response using the server_tokens option. | COMMENT |
| MEDIUM | patroni/dcs/zookeeper.py | 41 | """This method is trying to establish connection with one of the zookeeper nodes. | STRING |
| MEDIUM | patroni/dcs/__init__.py | 1853 | # This method is always called with ``optime`` key, rest of the keys are optional. | COMMENT |
| MEDIUM | docs/conf.py | 7 | # This file is execfile()d with the current directory set to its | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/ha.py | 1779 | # If the scheduled action is in the far future, we shouldn't do anything and just return. | COMMENT |
| LOW | patroni/postgresql/validator.py | 465 | # likely an extension GUC, so just return as it is. Otherwise, if `name` is in `parameters`, it's likely a | COMMENT |
| LOW | patroni/postgresql/validator.py | 488 | # just pass down the list of settings defined in Patroni validators so :func:`_transform_parameter_value` will not | COMMENT |
| LOW | patroni/postgresql/config.py | 547 | # Previously we didn't backup pg_ident.conf, if file is missing just create empty | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | patroni/utils.py | 655 | CODE | |
| LOW | tests/test_ha.py | 112 | CODE |