Skip to content

v2.4.0 HA core ready#122

Merged
cayossarian merged 7 commits intomainfrom
v2_4_0
Mar 25, 2026
Merged

v2.4.0 HA core ready#122
cayossarian merged 7 commits intomainfrom
v2_4_0

Conversation

@cayossarian
Copy link
Copy Markdown
Member

Optional http injection from HA
Test maintenance
TLS defaults

Allow Home Assistant to inject a managed httpx client for the SPAN v2 bootstrap path and distinguish probe failures from real v1 panels so config flows can report connectivity errors correctly.
Advance the package version to 2.4.0 so the Home Assistant dependency can point at the HTTP injection and probe-failure handling changes on this branch.
Parse proximityProven from the v2 status endpoint response. The field
is optional (added in firmware 202609); defaults to None on older
panels so callers can distinguish "not proven" from "unknown."
…emaTypes alias

Move temp CA cert file write into the executor alongside TLS+connect
so no synchronous file I/O runs on the event loop. Move cert cleanup
in disconnect to executor via run_in_executor.

Remove verify=False from the fallback httpx client — all bootstrap
URLs are plain HTTP so SSL verification is irrelevant, and the flag
looks like a security shortcut at first glance.

Narrow the CA cert download except clause from bare Exception to
specific transport and API errors.

Add HomieSchemaTypes type alias for the heterogeneous Homie schema
dict, replacing raw dict[str, dict[str, object]] throughout.
Cover new/removed node types, new/removed properties, changed
attributes, no-drift case, and non-dict property skipping. Raises
field_metadata.py coverage from 58% to 98%.
Strip tests that exercise Python mechanics (dataclass construction,
equality, frozen, slots, IntFlag, auto), tautological input==output
assertions, fragile source-code string inspection via
inspect.getsource, redundant hasattr/export checks, duplicate tests
across files, and one zero-assertion diagnostic print function.
Document proximity_proven, injected HTTP client, executor file I/O,
HomieSchemaTypes alias, narrowed exception handling, verify=False
removal, and test cleanup.
@cayossarian cayossarian merged commit 44fe136 into main Mar 25, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant