Fix Python setup in CI
Tests / tests (push) Successful in 1m10s

This commit is contained in:
buzera committed 2026-10-26 20:13:15 +02:00
1 parent 9ed62885b7
commit 43f30dab2b
3 files changed
+28 -6

No files matched your search

+11 -5
View File
@@ -8,11 +8,17 @@ jobs:
runs-on: bs-node runs-on: bs-node
steps: steps:
- uses: https://github.com/actions/checkout@v4 - uses: https://github.com/actions/checkout@v4
- uses: https://github.com/actions/setup-python@v5 # uv supplies standalone Python builds for the Debian job container.
- uses: https://github.com/astral-sh/setup-uv@v6
with: with:
python-version: '3.13' version: '0.9.6'
cache: pip enable-cache: false
github-token: ''
- name: Create Python environment
run: uv venv --python 3.13 --seed .venv
- name: Install test dependencies - name: Install test dependencies
run: python -m pip install -r requirements-test.txt run: uv pip install --python .venv/bin/python -r requirements-test.txt
- name: Run checks - name: Run checks
run: sh scripts/check.sh run: |
. .venv/bin/activate
sh scripts/check.sh
+11
View File
@@ -124,3 +124,14 @@ Remote runner execution, a modern-HA version matrix, dedicated lint/type checks,
full process restart, partial platform failure and real disk-failure testing remain full process restart, partial platform failure and real disk-failure testing remain
open. The test harness needed a pycares 4.11.0 pin for compatibility with HA's DNS open. The test harness needed a pycares 4.11.0 pin for compatibility with HA's DNS
dependency. Integration runtime dependencies and behavior are unchanged. dependency. Integration runtime dependencies and behavior are unchanged.
## CI provisioning correction
Remote CI reached checkout on the dedicated `bs-node` runner but failed at
setup-python: no Python 3.13 x64 build matched the Debian Bookworm job OS. No tests
ran in that job. The workflow now uses setup-uv v6 with uv 0.9.6 to create a seeded
Python 3.13 virtual environment, then runs the same dependency and test checks.
GitHub cache services are disabled and no Gitea token is supplied to setup-uv.
The runner label and integration runtime are unchanged. Remote execution of the
corrected workflow remains to be verified.
+6 -1
View File
@@ -158,7 +158,12 @@ still works without installing HA.
`.gitea/workflows/tests.yml` runs the same checks for pushes and pull requests on `.gitea/workflows/tests.yml` runs the same checks for pushes and pull requests on
the dedicated `bs-node` Actions runner label (`bs-node:docker://node:22-bookworm`). Repository Actions must be enabled. the dedicated `bs-node` Actions runner label (`bs-node:docker://node:22-bookworm`). Repository Actions must be enabled.
The runner must support checkout/setup-python and Python 3.13 dependencies. Dependencies and action downloads need internet access in CI; The runner must support the checkout and setup-uv actions. CI uses pinned uv
0.9.6 to create a Python 3.13 virtual environment from standalone Python builds;
`setup-python` cannot provision this version in the Debian Bookworm job image.
The environment includes pip for the existing check script. Action caching is
explicitly disabled to avoid requiring GitHub cache services on Gitea.
Dependencies, Python builds and action downloads need internet access in CI;
model inference does not. Remote CI execution has not yet been verified. Local model inference does not. Remote CI execution has not yet been verified. Local
validation used macOS and Python 3.13; Linux runner validation remains necessary. validation used macOS and Python 3.13; Linux runner validation remains necessary.
No runtime integration behavior or manifest version changed in this test commit. No runtime integration behavior or manifest version changed in this test commit.