Skip to content

v2.0.2 - MH200N Energy Profile & Command Session Hardening

Choose a tag to compare

@GreenGrassBlueOcean GreenGrassBlueOcean released this 24 Nov 09:34
c48f98a

OWNd 2.0.2

Gateway profile and command-session hardening since 2.0.1 (#184, #185, #186). No breaking API changes.

pip install OWNd==2.0.2

Changed

  • MH200NProfile (#184): includes WHO 18 (WHO_ENERGY) and inherits supports_energy_instant_power = True, backed by live MH200N 1.1.8 captures and the 010108 firmware oracle (bt_supervisione). MH200Profile is unchanged.
  • OWNCommandSession.send / send_to_gateway (#185): holds SEND_AUTH_COOLDOWN (60 s) after a fatal negotiation refusal (password_error, password_required, negotiation_error) until credentials/gateway change or explicit connect(), and returns None from send_to_gateway(raise_on_error=False) on a failed connect() without calling send().

Fixed

  • OWNCommandSession.send (#186): detects gateway peer closes behind buffered unsolicited frames (e.g. *#*0## + FIN after 30 s idle) via asyncio StreamReader._eof so the session reopens cleanly before the next write.
  • OWNCommandSession (#184): guards connect() result checks with isinstance(result, Mapping) in connect(), send_to_gateway(), probe_gateway(), and _locked_send() to prevent unawaited-coroutine RuntimeWarnings or accidental truthy "Success" matches on bare AsyncMock patches; CI now enforces error::RuntimeWarning.

Full changelog: v2.0.1...v2.0.2