AI Slop Code Risk Monitor

al-one/hass-xiaomi-miot

SlopCodeMonitor badge for al-one/hass-xiaomi-miot Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).

Automatic integrate all Xiaomi devices to HomeAssistant via miot-spec, support Wi-Fi, BLE, ZigBee devices. 小米米家智能家居设备接入Hass集成

11.6 Moderate pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for al-one/hass-xiaomi-miot, a Python project with 6,219 GitHub stars. SynthScan examined 43,372 lines of code across 120 source files, recording 418 pattern matches distributed across 10 syntactic categories. The legacy adjusted pattern signal is 11.6 (Moderate pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

11.6
Adjusted Signal
11.6
Raw Pattern Score
100%
Time Factor
2026-10-31
Last Push
6.2K
Stars
Python
Language
43.4K
Lines of Code
120
Files
418
Pattern Hits
2026-10-31
Scan Date
0.13
HC Hit Rate

Risk Review · Payload v1

Use each vector to guide manual verification of the underlying findings.

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.

Cognitive Ownership Risk 30.6/100 · MEDIUM

Can maintainers explain intent, assumptions, and trade-offs? 303 finding(s).

Hallucinated Dependency & Supply Chain Risk 8.0/100 · LOW

Are imports declared and package/API names verified? 59 finding(s).

Agent Over-Engineering Ratio 34.5/100 · MEDIUM

Are wrappers, guards, and repeated structures necessary? 294 finding(s).

PR Review Velocity Impact 44.1/100 · MEDIUM

Which changes need focused human review? 418 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 0HIGH 16MEDIUM 3LOW 399

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 418 distinct pattern matches across 10 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. 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 configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Hyper-Verbose Identifiers236 hits · 250 pts
SeverityFileLineSnippetContext
LOWtests/test_device_tracker.py4def test_tracker_does_not_override_deprecated_properties():CODE
LOW⚡tests/test_device_connection_modes.py45async def test_periodic_read_respects_mode(hass, mode, local):CODE
LOW⚡tests/test_device_connection_modes.py52async def test_local_read_failure_never_uses_cloud_even_with_explicit_fallback(hass):CODE
LOW⚡tests/test_device_connection_modes.py60async def test_auto_read_failure_falls_back_to_cloud(hass):CODE
LOW⚡tests/test_device_connection_modes.py67async def test_local_manual_read_retries_local_after_failure(hass):CODE
LOW⚡tests/test_device_connection_modes.py76async def test_local_write_ignores_cloud_override_and_does_not_retry(hass):CODE
LOWtests/test_device_connection_modes.py89async def test_local_action_ignores_cloud_override(hass):CODE
LOWtests/test_device_connection_modes.py99async def test_write_and_action_respect_mode_before_first_poll(hass, mode, local):CODE
LOWtests/test_cloud_auth_verify.py16async def test_verify_ticket_missing_url_raises_micloud(hass):CODE
LOWtests/test_cloud_auth_verify.py23async def test_verify_ticket_missing_identity_session_raises_micloud(hass):CODE
LOWtests/test_cloud_auth_verify.py36async def test_verify_ticket_non_zero_each_method_raises_verification(hass):CODE
LOWtests/test_cloud_auth_verify.py48async def test_verify_ticket_success_returns_data(hass):CODE
LOWtests/test_cloud_auth_verify.py61async def test_verify_ticket_no_supported_method_raises_micloud(hass):CODE
LOWtests/test_cloud_auth_verify.py71async def test_verify_ticket_pins_trust_false_and_payload(hass):CODE
LOWtests/conftest.py17def auto_enable_custom_integrations(enable_custom_integrations):CODE
LOWtests/test_topwit_rz01.py15def test_declared_temperature_code_is_normalized_to_a_standard_value():CODE
LOWtests/test_topwit_rz01.py27def test_recode_only_applies_to_declared_properties():CODE
LOWtests/test_topwit_rz01.py39def test_undeclared_recode_keeps_the_response_unchanged():CODE
LOWtests/test_climate_ma2_fan_level.py25def test_climate_prefers_discrete_fan_level_over_stepless(make_device, load_miot_spec):CODE
LOWtests/test_climate_ma2_fan_level.py35def test_climate_stepless_fan_alone_still_works(make_device, load_miot_spec):CODE
LOWtests/test_padw2p_lan.py26async def test_lan_mapping_uses_existing_chunking(hass):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py28def test_exact_model_converter_mapping(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py75def test_parent_entity_metadata_and_identity(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py159def test_air_conditioner_modes_and_ventilation_preset(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py171def test_floor_heating_power_state_and_partial_updates(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py209async def test_floor_heating_writes_only_assigned_properties(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py234async def test_air_conditioner_writes_only_assigned_properties(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py277def test_fresh_air_speed_mapping(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py299async def test_fresh_air_write_matrix(make_device, load_miot_spec):CODE
LOWtests/test_cnhdm_airrtc_wkq01.py359async def test_registry_preserves_air_conditioner_identity_across_reload(CODE
LOWtests/test_reauth_flow.py27async def test_reauth_unsupported_sid_aborts(flow_cls):CODE
LOWtests/test_reauth_flow.py46async def test_reauth_default_xiaomiio_when_init_data_omits_sid(flow_cls):CODE
LOWtests/test_reauth_flow.py67def test_async_remove_is_callback(flow_cls):CODE
LOWtests/test_reauth_flow.py72async def test_async_remove_clears_candidate(flow_cls):CODE
LOWtests/test_reauth_flow.py87async def test_reauth_password_invalid_auth_returns_invalid_auth(flow_cls):CODE
LOWtests/test_reauth_flow.py115async def test_reauth_password_need_verify_routes_to_verify(flow_cls):CODE
LOWtests/test_reauth_flow.py148async def test_reauth_password_wrong_account_aborts(flow_cls):CODE
LOWtests/test_reauth_flow.py177async def test_reauth_verify_empty_ticket_keeps_form_with_need_verify(flow_cls):CODE
LOWtests/test_reauth_flow.py198async def test_reauth_verify_verification_error_keeps_form(flow_cls):CODE
LOWtests/test_reauth_flow.py218async def test_reauth_verify_micoapi_sts_retry_runs_once(flow_cls):CODE
LOWtests/test_reauth_flow.py258async def test_reauth_verify_micoapi_second_sts_returns_unknown(flow_cls):CODE
LOWtests/test_reauth_flow.py287async def test_reauth_captcha_empty_keeps_form(flow_cls):CODE
LOWtests/test_reauth_flow.py312async def test_reauth_captcha_replaced_image_stays_with_need_captcha(flow_cls):CODE
LOWtests/test_reauth_flow.py339async def test_reauth_captcha_auth_error_without_challenge_returns_password(flow_cls):CODE
LOWtests/test_reauth_flow.py363async def test_persist_xiaomiio_updates_entry_invalidates_and_reloads(flow_cls):CODE
LOWtests/test_reauth_flow.py430async def test_persist_unchanged_with_listeners_skips_reload(flow_cls):CODE
LOWtests/test_reauth_flow.py484async def test_persist_micoapi_does_not_store_micoapi_tokens_in_entry(flow_cls):CODE
LOWtests/test_reauth_flow.py534async def test_persist_store_failure_returns_save_failed(flow_cls):CODE
LOWtests/test_reauth_flow.py574async def test_reauth_password_form_exposes_only_tip(flow_cls):CODE
LOWtests/test_reauth_flow.py585async def test_reauth_verify_form_exposes_only_tip_and_url(flow_cls):CODE
LOWtests/test_reauth_flow.py599async def test_reauth_captcha_form_exposes_only_tip_and_image(flow_cls):CODE
LOWtests/test_hass_entry_cloud.py31async def test_first_get_cloud_creates_xiaomiio(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py44async def test_concurrent_get_cloud_xiaomiio_only_creates_once(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py63async def test_get_cloud_micoapi_runs_single_probe(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py76async def test_get_cloud_micoapi_caches_terminal_none(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py96async def test_imic_com_has_no_micoapi_probe(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py109async def test_get_cloud_string_sid_coerced(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py121async def test_cloud_property_returns_xiaomiio_slot(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py134async def test_get_cloud_login_false_skips_login(entry, hass):CODE
LOWtests/test_hass_entry_cloud.py146async def test_async_change_sid_delegates_to_async_get_cloud(entry, hass):CODE
176 more matches not shown…
Empty Error Handlers14 hits · 70 pts
SeverityFileLineSnippetContext
HIGHcustom_components/xiaomi_miot/fan.py201except Exception:CODE
HIGHcustom_components/xiaomi_miot/media_player.py223except (TypeError, ValueError):CODE
HIGHcustom_components/xiaomi_miot/__init__.py1312except (TypeError, ValueError):CODE
HIGHcustom_components/xiaomi_miot/vacuum.py282except (DeviceException, Exception):CODE
HIGHcustom_components/xiaomi_miot/camera.py607except (TypeError, ValueError):CODE
HIGHcustom_components/xiaomi_miot/climate.py543except (Exception, NotImplementedError):CODE
HIGHcustom_components/xiaomi_miot/config_flow.py124except DeviceException:CODE
HIGHcustom_components/xiaomi_miot/core/device.py102except ValueError:CODE
HIGHcustom_components/xiaomi_miot/core/device.py109except ValueError:CODE
HIGHcustom_components/xiaomi_miot/core/utils.py234except KeyError:CODE
HIGHcustom_components/xiaomi_miot/core/utils.py245except (KeyError, Exception):CODE
HIGHcustom_components/xiaomi_miot/core/mini_miio.py106except Exception:CODE
HIGHcustom_components/xiaomi_miot/core/mini_miio.py266except Exception:CODE
HIGHcustom_components/xiaomi_miot/core/mini_miio.py317except (asyncio.TimeoutError, OSError):CODE
Deep Nesting63 hits · 63 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_miot/cover.py64CODE
LOWcustom_components/xiaomi_miot/cover.py139CODE
LOWcustom_components/xiaomi_miot/sensor.py54CODE
LOWcustom_components/xiaomi_miot/sensor.py83CODE
LOWcustom_components/xiaomi_miot/sensor.py242CODE
LOWcustom_components/xiaomi_miot/sensor.py336CODE
LOWcustom_components/xiaomi_miot/sensor.py402CODE
LOWcustom_components/xiaomi_miot/alarm_control_panel.py75CODE
LOWcustom_components/xiaomi_miot/fan.py73CODE
LOWcustom_components/xiaomi_miot/fan.py133CODE
LOWcustom_components/xiaomi_miot/fan.py167CODE
LOWcustom_components/xiaomi_miot/light.py72CODE
LOWcustom_components/xiaomi_miot/remote.py96CODE
LOWcustom_components/xiaomi_miot/remote.py143CODE
LOWcustom_components/xiaomi_miot/humidifier.py46CODE
LOWcustom_components/xiaomi_miot/media_player.py92CODE
LOWcustom_components/xiaomi_miot/media_player.py411CODE
LOWcustom_components/xiaomi_miot/media_player.py629CODE
LOWcustom_components/xiaomi_miot/media_player.py864CODE
LOWcustom_components/xiaomi_miot/__init__.py471CODE
LOWcustom_components/xiaomi_miot/__init__.py473CODE
LOWcustom_components/xiaomi_miot/__init__.py882CODE
LOWcustom_components/xiaomi_miot/__init__.py1182CODE
LOWcustom_components/xiaomi_miot/vacuum.py41CODE
LOWcustom_components/xiaomi_miot/vacuum.py118CODE
LOWcustom_components/xiaomi_miot/vacuum.py260CODE
LOWcustom_components/xiaomi_miot/camera.py59CODE
LOWcustom_components/xiaomi_miot/camera.py366CODE
LOWcustom_components/xiaomi_miot/camera.py409CODE
LOWcustom_components/xiaomi_miot/camera.py469CODE
LOWcustom_components/xiaomi_miot/text.py48CODE
LOWcustom_components/xiaomi_miot/binary_sensor.py43CODE
LOWcustom_components/xiaomi_miot/binary_sensor.py161CODE
LOWcustom_components/xiaomi_miot/binary_sensor.py219CODE
LOWcustom_components/xiaomi_miot/binary_sensor.py317CODE
LOWcustom_components/xiaomi_miot/water_heater.py141CODE
LOWcustom_components/xiaomi_miot/climate.py121CODE
LOWcustom_components/xiaomi_miot/climate.py164CODE
LOWcustom_components/xiaomi_miot/climate.py255CODE
LOWcustom_components/xiaomi_miot/climate.py348CODE
LOWcustom_components/xiaomi_miot/climate.py415CODE
LOWcustom_components/xiaomi_miot/device_tracker.py42CODE
LOWcustom_components/xiaomi_miot/config_flow.py74CODE
LOWcustom_components/xiaomi_miot/config_flow.py162CODE
LOWcustom_components/xiaomi_miot/config_flow.py201CODE
LOWcustom_components/xiaomi_miot/config_flow.py785CODE
LOWcustom_components/xiaomi_miot/core/hass_entity.py113CODE
LOWcustom_components/xiaomi_miot/core/device.py459CODE
LOWcustom_components/xiaomi_miot/core/device.py906CODE
LOWcustom_components/xiaomi_miot/core/device.py1068CODE
LOWcustom_components/xiaomi_miot/core/device.py1161CODE
LOWcustom_components/xiaomi_miot/core/device.py1234CODE
LOWcustom_components/xiaomi_miot/core/device.py1291CODE
LOWcustom_components/xiaomi_miot/core/miio2miot.py57CODE
LOWcustom_components/xiaomi_miot/core/miio2miot.py112CODE
LOWcustom_components/xiaomi_miot/core/miio2miot.py173CODE
LOWcustom_components/xiaomi_miot/core/utils.py108CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py465CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py289CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py458CODE
3 more matches not shown…
Unused Imports57 hits · 57 pts
SeverityFileLineSnippetContext
LOWtests/test_climate_ma2_fan_level.py10CODE
LOWtests/test_cnhdm_airrtc_wkq01.py11CODE
LOWtests/test_cnhdm_airrtc_wkq01.py11CODE
LOWtests/test_cnhdm_airrtc_wkq01.py11CODE
LOWtests/test_hass_entry_cloud.py12CODE
LOWtests/test_cloud_auth_step1.py2CODE
LOWtests/test_cloud_auth_step1.py3CODE
LOWtests/test_cloud_auth_step2.py4CODE
LOWtests/test_cloud_auth_owner.py5CODE
LOWtests/test_cloud_auth_types.py4CODE
LOWcustom_components/xiaomi_miot/time.py9CODE
LOWcustom_components/xiaomi_miot/cover.py12CODE
LOWcustom_components/xiaomi_miot/sensor.py22CODE
LOWcustom_components/xiaomi_miot/alarm_control_panel.py11CODE
LOWcustom_components/xiaomi_miot/fan.py11CODE
LOWcustom_components/xiaomi_miot/light.py16CODE
LOWcustom_components/xiaomi_miot/remote.py4CODE
LOWcustom_components/xiaomi_miot/remote.py17CODE
LOWcustom_components/xiaomi_miot/number.py11CODE
LOWcustom_components/xiaomi_miot/humidifier.py12CODE
LOWcustom_components/xiaomi_miot/media_player.py38CODE
LOWcustom_components/xiaomi_miot/__init__.py36CODE
LOWcustom_components/xiaomi_miot/__init__.py38CODE
LOWcustom_components/xiaomi_miot/vacuum.py13CODE
LOWcustom_components/xiaomi_miot/switch.py11CODE
LOWcustom_components/xiaomi_miot/camera.py28CODE
LOWcustom_components/xiaomi_miot/button.py9CODE
LOWcustom_components/xiaomi_miot/text.py9CODE
LOWcustom_components/xiaomi_miot/binary_sensor.py15CODE
LOWcustom_components/xiaomi_miot/select.py11CODE
LOWcustom_components/xiaomi_miot/water_heater.py15CODE
LOWcustom_components/xiaomi_miot/climate.py30CODE
LOWcustom_components/xiaomi_miot/device_tracker.py14CODE
LOWcustom_components/xiaomi_miot/core/hass_entity.py13CODE
LOWcustom_components/xiaomi_miot/core/hass_entity.py17CODE
LOWcustom_components/xiaomi_miot/core/coordinator.py9CODE
LOWcustom_components/xiaomi_miot/core/device.py35CODE
LOWcustom_components/xiaomi_miot/core/device_customizes.py25CODE
LOWcustom_components/xiaomi_miot/core/__init__.py1CODE
LOWcustom_components/xiaomi_miot/core/__init__.py1CODE
LOWcustom_components/xiaomi_miot/core/__init__.py2CODE
LOWcustom_components/xiaomi_miot/core/__init__.py3CODE
LOWcustom_components/xiaomi_miot/core/__init__.py3CODE
LOWcustom_components/xiaomi_miot/core/utils.py15CODE
LOWcustom_components/xiaomi_miot/core/converters.py6CODE
LOWcustom_components/xiaomi_miot/core/converters.py7CODE
LOWcustom_components/xiaomi_miot/core/converters.py7CODE
LOWcustom_components/xiaomi_miot/core/converters.py7CODE
LOWcustom_components/xiaomi_miot/core/const.py5CODE
LOWcustom_components/xiaomi_miot/core/const.py5CODE
LOWcustom_components/xiaomi_miot/core/const.py6CODE
LOWcustom_components/xiaomi_miot/core/const.py8CODE
LOWcustom_components/xiaomi_miot/core/const.py8CODE
LOWcustom_components/xiaomi_miot/core/const.py9CODE
LOWcustom_components/xiaomi_miot/core/const.py10CODE
LOWcustom_components/xiaomi_miot/core/const.py59CODE
LOWcustom_components/xiaomi_miot/core/const.py59CODE
Excessive Try-Catch Wrapping41 hits · 44 pts
SeverityFileLineSnippetContext
LOWtests/test_media_player_micoapi.py33 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/fan.py201 except Exception:CODE
MEDIUMcustom_components/xiaomi_miot/fan.py196def _proactive_update(now):CODE
LOWcustom_components/xiaomi_miot/remote.py209 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/media_player.py361 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/__init__.py289 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/__init__.py300 except Exception:CODE
LOWcustom_components/xiaomi_miot/__init__.py428 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/__init__.py510 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/config_flow.py517 except Exception:CODE
LOWcustom_components/xiaomi_miot/config_flow.py622 except Exception:CODE
LOWcustom_components/xiaomi_miot/config_flow.py630 except Exception:CODE
LOWcustom_components/xiaomi_miot/config_flow.py699 except Exception:CODE
LOWcustom_components/xiaomi_miot/config_flow.py738 except Exception:CODE
LOWcustom_components/xiaomi_miot/config_flow.py761 except Exception:CODE
MEDIUMcustom_components/xiaomi_miot/config_flow.py735def _persist_and_reload(self, candidate):CODE
LOWcustom_components/xiaomi_miot/core/hass_entity.py184 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/device.py119 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/device.py989 except Exception as refresh_exc: # noqa: BLE001CODE
LOWcustom_components/xiaomi_miot/core/utils.py119 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/hass_entry.py153 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py83 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py267 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py301 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py657 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py690 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py853 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/xiaomi_cloud.py880 except Exception:CODE
MEDIUMcustom_components/xiaomi_miot/core/xiaomi_cloud.py77def __init__(self, hass, username, password, country=None, sid=None, hass_entry=CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py106 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py153 except Exception as e:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py191 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py234 except Exception as e:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py266 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py320 except Exception as e:CODE
LOWcustom_components/xiaomi_miot/core/mini_miio.py347 except Exception:CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py330 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py372 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py444 except Exception as exc:CODE
LOWcustom_components/xiaomi_miot/core/miot_spec.py476 except Exception as exc:CODE
LOWscripts/mcp-tools.py22 except Exception:CODE
Cross-Language Confusion2 hits · 15 pts
SeverityFileLineSnippetContext
HIGH⚡tests/test_power_cost_statistics.py295 {'time': int(midnight.timestamp()), 'value': '[null]'},CODE
HIGH⚡tests/test_power_cost_statistics.py362@pytest.mark.parametrize('value', ['not-json', '', '[]', '[null]', '[true]',CODE
AI Structural Patterns2 hits · 2 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_miot/system_health.py40CODE
LOWcustom_components/xiaomi_miot/core/miio2miot.py171CODE
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_miot/core/device.py99 # Check if token is valid hexadecimal, otherwise try extra.tokenCOMMENT
Modern Structural Boilerplate1 hit · 1 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_miot/core/__init__.py5__all__ = [CODE
Over-Commented Block1 hit · 1 pts
SeverityFileLineSnippetContext
LOWcustom_components/xiaomi_miot/core/miio2miot_specs.py1481 # "Espresso_Coffee_Set [coffee.coffee, coffee.temp],COMMENT