Skip to content

chore: bump dev toolchain to Python 3.14, add HA 2026-latest matrix cell#39

Merged
DefinitelyADev merged 2 commits into
masterfrom
chore/py314-matrix-bump
May 27, 2026
Merged

chore: bump dev toolchain to Python 3.14, add HA 2026-latest matrix cell#39
DefinitelyADev merged 2 commits into
masterfrom
chore/py314-matrix-bump

Conversation

@DefinitelyADev

Copy link
Copy Markdown
Owner

Summary

Adds a 4th CI matrix cell on Python 3.14 / HA 2026-latest, moves the non-matrix jobs (lint, type-check, validate, pre-commit) to py3.14, and bumps requirements-dev.txt floors to homeassistant>=2026.5.4 and pytest-homeassistant-custom-component>=0.13.333. This unblocks Dependabot PRs #30 and #31, which were stuck because both target dependencies require Python ≥3.14 / ≥3.14.2.

Why

  • phacc 0.13.317+ → Requires-Python >=3.14
  • HA 2026.3.0+ → Requires-Python >=3.14.2

The matrix was capped at py3.13, so pip install -r requirements-dev.txt failed on PRs that bumped either floor. The existing py3.13 / HA 2026 / phacc==0.13.316 cell stays as the "last py3.13" boundary — the new cell sits beside it for the moving HA head.

Changes

.github/workflows/ci.yml

  • Add 4th matrix cell: py3.14 / ha-version=2026-latest / phacc==0.13.333.
  • validate, type-check, lint jobs: setup-python 3.133.14.

.github/workflows/pre-commit.yml

  • setup-python 3.133.14.

requirements-dev.txt

  • homeassistant>=2023.6.0>=2026.5.4.
  • pytest-homeassistant-custom-component>=0.13.298,<0.13.317>=0.13.333. The upper cap existed only to keep py3.13 dev installs away from py3.14-gated phacc — no longer needed since the dev floor is now py3.14.

AGENTS.md and CLAUDE.md

  • "3-cell matrix" → "4-cell matrix"; note that non-matrix jobs are on py3.14 because of the requirements-dev.txt floor.

Pre-flight already done

  • actions/setup-python@v6 resolves Python 3.14.2/3/4/5 on ubuntu-24.04 (latest stable 3.14.5).
  • ✅ All dev tools (mypy 2.1.0, pre-commit 4.6.0, black 26.5.1, isort 8.0.1, flake8 7.3.0, ruff 0.15.14, pyright 1.1.409, pytest 9.0.3, pytest-cov 7.1.0, voluptuous 0.16.0, phacc 0.13.333, homeassistant 2026.5.4) ship py3.14-compatible wheels.
  • Not run locally: python check_all.py — toolchain now requires py3.14.2+ which isn't installed locally. CI is the verification.

Test plan

Not in scope

  • manifest.json HA floor (2024.4.0) stays — runtime support for older HA is independent of dev tooling.
  • CHANGELOG entry — convention has been to add CI/dev-tooling entries at release time, not per-PR.
  • .github/dependabot.yml ignore list — no longer needed if this PR works; revisit only if the matrix bump is reverted.

🤖 Generated with Claude Code

CI:
- Add 4th matrix cell: py3.14 / HA 2026-latest / phacc 0.13.333.
  phacc 0.13.317+ requires Python 3.14; HA 2026.3.0+ requires
  Python 3.14.2. The existing py3.13/HA 2026 cell stays as the
  last-supported py3.13 boundary.
- Move lint, type-check, validate, and pre-commit jobs to py3.14.
  They install requirements-dev.txt directly, so the bumped
  homeassistant>=2026.5.4 floor below forces py3.14 here.

requirements-dev.txt:
- homeassistant: 2023.6.0 -> 2026.5.4 (was a stale dev-only floor).
- pytest-homeassistant-custom-component: drop the <0.13.317 upper
  cap (it existed only to keep the py3.14 wall away on py3.13
  dev installs); floor bumped to 0.13.333 to match the new matrix
  cell.

Docs:
- AGENTS.md and CLAUDE.md updated to describe the 4-cell matrix
  and explain why the non-matrix jobs are on py3.14.

Note: not running local check_all.py — toolchain now requires
py3.14.2+ which is not installed locally. CI is the verification.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added dependencies Pull requests that update a dependency file github_actions Pull requests that update GitHub Actions code labels May 27, 2026
@codecov

codecov Bot commented May 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.51%. Comparing base (21ca35c) to head (b4c7465).

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #39   +/-   ##
=======================================
  Coverage   91.51%   91.51%           
=======================================
  Files          10       10           
  Lines         849      849           
  Branches       79       79           
=======================================
  Hits          777      777           
  Misses         49       49           
  Partials       23       23           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

mypy was running on Python 3.14 (lint/pre-commit jobs) but
python_version="3.13" told it to refuse py3.14-specific syntax.
HA 2026.5.4's device_registry.py uses an except expression without
parentheses (py3.14 syntax), so mypy's parse aborted before any
of our code was checked. Bumping to 3.14 matches the runtime
toolchain and lets mypy parse HA's installed source.

Our integration code does not use py3.14-only syntax — black's
target-version stays at py313 and other linters are unchanged.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@DefinitelyADev DefinitelyADev merged commit c1e3f25 into master May 27, 2026
17 checks passed
@DefinitelyADev DefinitelyADev deleted the chore/py314-matrix-bump branch May 27, 2026 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file github_actions Pull requests that update GitHub Actions code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant