Test against current Home Assistant on Python 3.14, add shared CI and security scans #1
Loading…
Reference in a new issue
No description provided.
Delete branch "chore/maintenance-2026-10"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Maintenance run. Eight commits.
Findings
pyproject.tomlpinnedhomeassistant==2025.12.4andpytest==9.0.0, which conflict with the current test plugin (pytest-homeassistant-custom-component0.13.372 pinshomeassistant==2026.10.1,pytest==9.0.3,pytest-asyncio==1.4.0). The resolver was held on an old plugin, so tests ran against HA 2025.12.asyncio_mode = "auto"was set (the plugin's async autouse fixtures are only handled in auto mode).requirements_dev.txtwas a second dev dependency list with 2024-era floors, referenced only in the docs.Commits
ruff-check).requires-python >=3.14,.tool-versions3.14, tool floors,asyncio_mode = "auto", removerequirements_dev.txt.pip install -e .[dev].DESIGN.md)..forgejo/workflows/ci.ymlandsecurity.ymlon the shared workflow-basics actions.manifest.json,hacs.json, README) and targets Python 3.14 in ruff. Only the latest HA is run, so no backwards compatibility.except (A, B):becomesexcept A, B:(PEP 758) in four modules. The ASTs are identical before and after.The security finding (commit 8)
The callers only ever pass
"max"/"last"and"1h"/"15m", and the sensor id comes from the config entry, so this was not exploitable in practice. Butquery_sensor_statisticsaccepts arbitrary strings, and a double quote in a measurement name broke out of the quoted identifier.Home Assistant's InfluxDB wrapper only exposes
query(query, database), so bind parameters are not available. Instead each interpolated value comes from a function that returns a safe value or raisesValueError:_aggregation()(allowlist),_interval(),_quote_identifier()(escapes\and"),_time_literal()(datetimes only), assembled by_build_statistics_query(). Invalid arguments are rejected before any query is sent. No# nosecis needed. 22 new tests, written first.Not included
pip-auditis off insecurity.yml: the dev extra is the full HA test environment, not what ships. The only runtime requirement isinfluxdb>=5.3.1(manifest).hassintest_learning_engine, andinfluxdb's ownutcfromtimestampdeprecation).# noqa: BLE001inconfig_flow.pyis untouched.Verified
ruff check,ruff format --checkandbandit -llpass on Python 3.14.8 in a clean container with no build tools.Claude-Session: https://claude.ai/code/session_013jL41LP9srdcUDYggNpC98
🤖 Generated with Claude Code