Repository Analysis

XiaoMi/ha_xiaomi_home

Xiaomi Home Integration for Home Assistant

11.9 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of XiaoMi/ha_xiaomi_home, a Python project with 22,061 GitHub stars. SynthScan v2.0 examined 32,975 lines of code across 97 source files, recording 261 pattern matches distributed across 11 syntactic categories. The overall adjusted score of 11.9 places this repository in the Low 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).

11.9
Adjusted Score
11.9
Raw Score
100%
Time Factor
2026-08-18
Last Push
22.1K
Stars
Python
Language
33.0K
Lines of Code
97
Files
261
Pattern Hits
2026-08-29
Scan Date
0.36
HC Hit Rate

What These Metrics Mean

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

Score History

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

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

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 0HIGH 35MEDIUM 8LOW 218

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 261 distinct pattern matches across 11 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.

Cross-File Repetition35 hits · 175 pts
SeverityFileLineSnippetContext
HIGHcustom_components/xiaomi_home/event.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/cover.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/sensor.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/fan.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/light.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/number.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/humidifier.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/media_player.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/__init__.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/notify.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/vacuum.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/switch.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/button.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/text.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/binary_sensor.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/select.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/water_heater.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/climate.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/device_tracker.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/config_flow.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_mips.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_network.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_lan.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_storage.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_i18n.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_client.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_device.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/common.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/web_pages.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_error.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_mdns.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/const.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_spec.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGHcustom_components/xiaomi_home/miot/miot_cloud.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
HIGH…stom_components/xiaomi_home/miot/specs/specv2entity.py0copyright (c) 2024 xiaomi corporation. the ownership and intellectual property rights of xiaomi home assistant integratiSTRING
Hyper-Verbose Identifiers94 hits · 84 pts
SeverityFileLineSnippetContext
LOWtest/test_spec.py59async def test_spec_random_parse_async(test_cache_path, test_lang):CODE
LOWtest/test_storage.py94async def test_multi_task_load_async(test_cache_path):CODE
LOWtest/test_storage.py115async def test_file_save_load_async(test_cache_path):CODE
LOWtest/test_network.py13async def test_network_monitor_loop_async():CODE
LOWtest/test_network.py17 async def on_network_status_changed(status: bool):CODE
LOWtest/test_mips.py81 async def on_mips_state_changed_async(key: str, state: bool):CODE
LOWtest/test_mips.py84 async def on_dev_list_changed_async(CODE
LOWtest/test_mips.py193 async def on_mips_state_changed_async(key: str, state: bool):CODE
LOWtest/test_cloud.py86async def test_miot_oauth_refresh_token(CODE
LOWtest/test_cloud.py138async def test_miot_cloud_get_nickname_async(CODE
LOWtest/test_cloud.py167async def test_miot_cloud_get_uid_async(CODE
LOWtest/test_cloud.py199async def test_miot_cloud_get_homeinfos_async(CODE
LOWtest/test_cloud.py245async def test_miot_cloud_get_devices_async(CODE
LOWtest/test_cloud.py297async def test_miot_cloud_get_devices_with_dids_async(CODE
LOWtest/test_cloud.py418async def test_miot_cloud_get_prop_async(CODE
LOWtest/test_cloud.py455async def test_miot_cloud_get_props_async(CODE
LOWtest/test_cloud.py494async def test_miot_cloud_set_prop_async(CODE
LOWtest/test_cloud.py545async def test_miot_cloud_action_async(CODE
LOWcustom_components/xiaomi_home/cover.py214 def _position_changed_handler(self, prop: MIoTSpecProperty,CODE
LOWcustom_components/xiaomi_home/media_player.py270 async def async_media_previous_track(self) -> None:CODE
LOWcustom_components/xiaomi_home/__init__.py325async def async_remove_config_entry_device(CODE
LOWcustom_components/xiaomi_home/config_flow.py314 async def async_step_network_detect_config(CODE
LOWcustom_components/xiaomi_home/config_flow.py394 async def __show_network_detect_config_form(self, reason: str):CODE
LOWcustom_components/xiaomi_home/config_flow.py740 async def async_step_advanced_options(CODE
LOWcustom_components/xiaomi_home/config_flow.py789 async def async_step_devices_filter(CODE
LOWcustom_components/xiaomi_home/config_flow.py866 async def __show_devices_filter_form(self, reason: str):CODE
LOWcustom_components/xiaomi_home/config_flow.py1308 async def async_step_config_options(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py1405 async def async_step_update_user_info(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py1543 async def async_step_devices_filter(CODE
LOWcustom_components/xiaomi_home/config_flow.py1609 async def __show_devices_filter_form(self, reason: str):CODE
LOWcustom_components/xiaomi_home/config_flow.py1706 async def update_devices_done_async(self):CODE
LOWcustom_components/xiaomi_home/config_flow.py1722 async def async_step_update_trans_rules(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py1758 async def async_step_update_lan_ctrl_config(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py1821 async def async_step_network_detect_config(CODE
LOWcustom_components/xiaomi_home/config_flow.py1903 async def __show_network_detect_config_form(self, reason: str):CODE
LOWcustom_components/xiaomi_home/config_flow.py1933 async def async_step_config_confirm(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py2140def _handle_network_detect_addr(CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py722 def __mips_sub_internal_pending_handler(self, ctx: Any) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py816 def __mips_start_connect_tries(self) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py842 def __get_next_reconnect_time(self) -> float:CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py1062 def __unreg_broadcast_external(self, topic: str) -> bool:CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py1405 async def get_action_group_list_async(CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py1417 async def exec_action_group_list_async(CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py1611 def __unreg_broadcast_external(self, topic) -> bool:CODE
LOWcustom_components/xiaomi_home/miot/miot_network.py332 def __call_network_info_change(CODE
LOWcustom_components/xiaomi_home/miot/miot_network.py338 async def __update_status_and_info_async(self) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py911 async def __on_network_info_change_external_async(CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1141 def __update_subscribe_option(self, options: dict) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_storage.py605 async def user_cert_remaining_time_async(CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py491 def hide_non_standard_entities(self) -> bool:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py496 def display_devices_changed_notify(self) -> list[str]:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py513 def display_devices_changed_notify(self, value: list[str]) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py940 def __request_refresh_auth_info(self, delay_sec: int) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py949 def __request_refresh_user_cert(self, delay_sec: int) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1029 async def __on_network_status_changed(self, status: bool) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1049 async def __on_mips_service_state_change(CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1091 async def __on_mips_cloud_state_changed(CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1129 async def __on_mips_local_state_changed(CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1175 async def __on_miot_lan_state_change(self, state: bool) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1223 def __on_cloud_device_state_changed(CODE
34 more matches not shown…
Excessive Try-Catch Wrapping55 hits · 57 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_home/__init__.py276 except Exception as err:CODE
MEDIUMcustom_components/xiaomi_home/config_flow.py1190def async_step_oauth(self, user_input=None):CODE
LOWcustom_components/xiaomi_home/config_flow.py387 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/config_flow.py467 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/config_flow.py529 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py550 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py565 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py632 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py708 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py1160 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py1232 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/config_flow.py1264 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py1435 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py1445 except Exception as err:CODE
LOWcustom_components/xiaomi_home/config_flow.py1896 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/config_flow.py2084 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/config_flow.py2156 except Exception:CODE
LOWcustom_components/xiaomi_home/config_flow.py2166 except Exception:CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py546 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py569 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py609 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py744 except Exception as err: # pylint: disable=broad-exception-caughtCODE
MEDIUMcustom_components/xiaomi_home/miot/miot_mips.py591def __mqtt_loop_handler(self) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_network.py236 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_network.py293 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_network.py303 except Exception: # pylint: disable=broad-exception-caughtCODE
MEDIUMcustom_components/xiaomi_home/miot/miot_network.py208def get_network_status_async(self) -> bool:CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py282 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py597 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1053 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1197 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1226 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1267 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1360 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_storage.py766 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_i18n.py87 except Exception as err: # pylint: disable=broad-exception-caughtCODE
MEDIUMcustom_components/xiaomi_home/miot/miot_client.py536def refresh_oauth_info_async(self) -> bool:CODE
MEDIUMcustom_components/xiaomi_home/miot/miot_client.py594def refresh_user_cert_async(self) -> bool:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py584 except Exception as err:CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py742 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1326 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1336 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1456 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_client.py1687 except Exception as err: # pylint:disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_device.py822 except Exception: # pylint: disable=broad-exceptCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py389 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py594 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py860 except Exception as err:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py871 except Exception as err:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py887 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py961 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1041 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1129 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1180 except Exception as err: # pylint: disable=broad-exception-caughtCODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1349 except Exception as err: # pylint: disable=broad-exception-caughtCODE
Deep Nesting41 hits · 36 pts
SeverityFileLineSnippetContext
LOWtest/check_rule_format.py153CODE
LOWtest/check_rule_format.py268CODE
LOWcustom_components/xiaomi_home/cover.py67CODE
LOWcustom_components/xiaomi_home/cover.py111CODE
LOWcustom_components/xiaomi_home/sensor.py65CODE
LOWcustom_components/xiaomi_home/fan.py110CODE
LOWcustom_components/xiaomi_home/light.py108CODE
LOWcustom_components/xiaomi_home/humidifier.py101CODE
LOWcustom_components/xiaomi_home/media_player.py406CODE
LOWcustom_components/xiaomi_home/__init__.py85CODE
LOWcustom_components/xiaomi_home/notify.py97CODE
LOWcustom_components/xiaomi_home/vacuum.py111CODE
LOWcustom_components/xiaomi_home/text.py119CODE
LOWcustom_components/xiaomi_home/climate.py315CODE
LOWcustom_components/xiaomi_home/climate.py499CODE
LOWcustom_components/xiaomi_home/climate.py658CODE
LOWcustom_components/xiaomi_home/device_tracker.py84CODE
LOWcustom_components/xiaomi_home/config_flow.py2140CODE
LOWcustom_components/xiaomi_home/config_flow.py497CODE
LOWcustom_components/xiaomi_home/config_flow.py663CODE
LOWcustom_components/xiaomi_home/config_flow.py1426CODE
LOWcustom_components/xiaomi_home/miot/miot_mips.py678CODE
LOWcustom_components/xiaomi_home/miot/miot_network.py338CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py1141CODE
LOWcustom_components/xiaomi_home/miot/miot_storage.py127CODE
LOWcustom_components/xiaomi_home/miot/miot_storage.py194CODE
LOWcustom_components/xiaomi_home/miot/miot_storage.py605CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py255CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py375CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py594CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py638CODE
LOWcustom_components/xiaomi_home/miot/miot_client.py770CODE
LOWcustom_components/xiaomi_home/miot/miot_device.py415CODE
LOWcustom_components/xiaomi_home/miot/miot_device.py622CODE
LOWcustom_components/xiaomi_home/miot/miot_device.py1164CODE
LOWcustom_components/xiaomi_home/miot/miot_device.py1436CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py303CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py754CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py839CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1399CODE
LOWcustom_components/xiaomi_home/miot/miot_cloud.py459CODE
Unused Imports19 hits · 19 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_home/event.py48CODE
LOWcustom_components/xiaomi_home/cover.py48CODE
LOWcustom_components/xiaomi_home/sensor.py48CODE
LOWcustom_components/xiaomi_home/fan.py48CODE
LOWcustom_components/xiaomi_home/light.py48CODE
LOWcustom_components/xiaomi_home/number.py48CODE
LOWcustom_components/xiaomi_home/humidifier.py48CODE
LOWcustom_components/xiaomi_home/media_player.py48CODE
LOWcustom_components/xiaomi_home/__init__.py48CODE
LOWcustom_components/xiaomi_home/notify.py48CODE
LOWcustom_components/xiaomi_home/vacuum.py48CODE
LOWcustom_components/xiaomi_home/switch.py48CODE
LOWcustom_components/xiaomi_home/button.py48CODE
LOWcustom_components/xiaomi_home/text.py48CODE
LOWcustom_components/xiaomi_home/binary_sensor.py48CODE
LOWcustom_components/xiaomi_home/select.py48CODE
LOWcustom_components/xiaomi_home/water_heater.py48CODE
LOWcustom_components/xiaomi_home/climate.py48CODE
LOWcustom_components/xiaomi_home/device_tracker.py48CODE
Modern Structural Boilerplate9 hits · 9 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_home/miot/miot_mips.py386 def update_mqtt_password(self, password: str) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py317 def update_info(self, info: dict) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py644 async def update_net_ifs_async(self, net_ifs: list[str]) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_lan.py679 async def update_subscribe_option(self, enable_subscribe: bool) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py839 async def set_spec_async(self, urn: str) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1062 async def set_spec_spec(self, urn_key: str) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1146 async def set_spec_async(self, urn: str) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_spec.py1197 async def set_spec_async(self, urn: str) -> None:CODE
LOWcustom_components/xiaomi_home/miot/miot_cloud.py116 def set_redirect_url(self, redirect_url: str) -> None:CODE
Redundant / Tautological Comments3 hits · 4 pts
SeverityFileLineSnippetContext
LOWinstall.sh11# Check if config path exists.COMMENT
LOWcustom_components/xiaomi_home/miot/miot_i18n.py90 # Check if the file is a valid JSON fileCOMMENT
LOWcustom_components/xiaomi_home/miot/miot_spec.py964 # Check if the file is a valid fileCOMMENT
Slop Phrases2 hits · 4 pts
SeverityFileLineSnippetContext
MEDIUMcustom_components/xiaomi_home/translations/en.json24 "description": "## Usage Introduction\r\n### Network Detection Address\r\nUsed to check if the network iCODE
MEDIUMcustom_components/xiaomi_home/translations/en.json179 "description": "## Usage Introduction\r\n### Network Detection Address\r\nUsed to check if the network iCODE
Self-Referential Comments1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMcustom_components/xiaomi_home/miot/miot_lan.py950# The following methods SHOULD ONLY be called in the internal loopCOMMENT
AI Structural Patterns1 hit · 1 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_home/miot/miot_device.py1328CODE
Over-Commented Block1 hit · 1 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_home/miot/miot_error.py61 CODE_TIMEOUT = -10006COMMENT