Skip to content

ci: one run per push, pinned actions and dev tools, pip cache - #220

Merged
lollox80 merged 1 commit into
mainfrom
ci/workflow-tidy
Oct 23, 2026
Merged

lollox80 merged 1 commit into
mainfrom
ci/workflow-tidy

Conversation

@lollox80

Copy link
Copy Markdown
Collaborator

What and why

CI tidy-up from the code audit. The six required checks keep their names; what they run does not change.

  • One CI run per push, not two. validate.yml ran on every push and on pull_request, so each push to a
    branch with a PR ran the whole suite twice. push is now limited to main; branches are checked through their
    PR, and the merge queue and the weekly run are unchanged. A ci/pr-N copy of a fork's PR
    no longer starts the suite by itself: it runs from workflow_dispatch.
  • Fixed versions. hassfest@master and hacs/action@main are pinned to the commits they point to today, and
    requirements-dev.txt uses == (the versions the CI installs today). A new release of an action or a tool can
    no longer turn the CI red on its own: Dependabot already watches both ecosystems and moves them once a month.
    Their own dependencies stay unpinned. Neither action SHA is on a release tag, so the first Dependabot PR for
    them is worth a look (it may offer an older tag).
  • One ruff pin. The ruff job installed ruff==0.16.10 while requirements-dev.txt said >=0.16.10 (so the
    test jobs got 0.17.2). The job now reads the version from requirements-dev.txt.
  • pip cache in the jobs that install requirements-dev.txt (pytest, the media/browser job, the Docker job).

A new tests/test_ci_pins.py keeps this in place (no action on a branch, every dev tool pinned, the ruff job
reading requirements-dev.txt, push only on main); its four tests fail on main.

Not in this PR: the live marker stays (no test uses it today, but AGENTS.md names it in the safety rules for
any test that would touch a real intercom); pycryptodome keeps its minimum of 3.19 in the manifest, while the
tests run 4.1.0.

Tested on

Windows 11, Python 3.13: CHECK VERDE: ci/workflow-tidy (f976e38) | ruff pulito | 2422 passed, 28 skipped, 111 deselected | copertura 97.15% (soglia 95%)

The workflows themselves run on this PR.

Field test: not needed (CI only).

Docs

Docs: not needed.

Changelog

Changelog: none

From the code audit. validate.yml ran on every push and on pull_request,
so a push to a branch with a PR ran the suite twice: push is now main
only. hassfest and the HACS action are pinned to today's commits and
requirements-dev.txt to today's versions, which Dependabot already moves
monthly; the ruff job reads its pin from requirements-dev.txt, so lint and
tests agree. The jobs that install requirements-dev.txt cache pip.
@lollox80
lollox80 added this pull request to the merge queue Oct 23, 2026
Merged via the queue into main with commit 7522666 Oct 23, 2026
8 checks passed
@lollox80
lollox80 deleted the ci/workflow-tidy branch October 23, 2026 01:30
@lollox80 lollox80 mentioned this pull request Oct 23, 2026
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