get rid of github ci/cd version check of package…

Todo: 2556952d
This commit is contained in:
Krzysztof Rudnicki 2026-11-19 20:46:45 +01:00
parent a7620e37b8
commit 62fa631b6b
6 changed files with 8 additions and 69 deletions

View File

@ -1,62 +0,0 @@
name: dependency freshness
# Every dependency on its ecosystem's newest STABLE release, enforced on push
# as well as at commit time. The local pre-commit hook only sees the manifests
# in a commit and can be skipped entirely by a fresh clone that never ran
# `pre-commit install`; this runs `--all` over the whole repo.
#
# `--strict` is CI-only. Offline the gate degrades to its cached answer and
# passes, because `--no-verify` is banned locally and a hook that hard-failed
# on a flaky connection would leave no way to commit. A runner is always
# online, so here an undeterminable answer is a real failure.
#
# Expect this to go red for reasons this repo's commit did not cause: an
# upstream release overnight is enough. That is the chosen behaviour -- the
# alternative is a gate that only notices staleness when someone remembers to
# look.
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
jobs:
dependency-freshness:
name: dependencies on newest stable
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# The gate lives in the shared utils repo so every repo resolves the
# same "latest stable" the same way. Checking it out beats vendoring a
# copy, which is exactly how a gate and its survey start disagreeing.
- name: Check out the shared gate
uses: actions/checkout@v4
with:
repository: kuhyx/utils
path: .utils
# "3.x", never a pinned minor: the Python target IS the interpreter the
# gate runs under (registries/toolchain.python_installed), so a runner
# held a release behind this machine reports a repo's `requires-python`
# as excluding "latest" while the same check passes locally. flax-docs-mcp
# hit exactly that -- `>=3.14` green here, red on a 3.13 runner.
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"
- name: Install the gate's two runtime dependencies
run: python -m pip install --upgrade pyyaml packaging
- name: Cache registry lookups
uses: actions/cache@v4
with:
path: ~/.cache/dep-freshness
key: dep-freshness-${{ hashFiles('**/pubspec.yaml', '**/pyproject.toml',
'**/requirements*.txt', '**/package.json', '**/Cargo.toml', '**/go.mod') }}
restore-keys: dep-freshness-
- name: Every dependency is on newest stable
run: bash .utils/scripts/check_dependency_freshness.sh --all --strict

View File

@ -28,9 +28,10 @@ jobs:
- group: flutter
hooks: flutter-analyze
skip: ""
# dependency-freshness is local only (pre-commit hook), never in CI.
- group: rest
hooks: ""
skip: mypy,pylint,flutter-analyze
skip: mypy,pylint,flutter-analyze,dependency-freshness
name: pre-commit (${{ matrix.group }})
steps:
- uses: actions/checkout@v4
@ -93,8 +94,7 @@ jobs:
# Every hook brings its own environment except the language: system
# ones, and those all run in `rest`: screens-fit imports screen_locker
# (and so its runtime deps) and dependency-freshness needs pyyaml and
# packaging. The other groups need pre-commit alone. uv with a cached
# (and so its runtime deps). The other groups need pre-commit alone. uv with a cached
# wheel store replaces a ~27 s pip install.
- name: Install requirements for the system hooks
if: matrix.group == 'rest'

View File

@ -9,7 +9,7 @@ on:
env:
# Bucket count for the Flutter suite; the matrix below lists 0..N-1.
# 10, not more: the account runs at most 20 jobs at once, and a push also
# starts ~10 others (pre-commit, freshness, the rest of this file). At 12
# starts ~10 others (pre-commit, the rest of this file). At 12
# three shards queued for up to 34 s and the workflow took 91 s.
FLUTTER_SHARDS: 10

View File

@ -459,7 +459,8 @@ repos:
# Runs WITHOUT --strict on purpose. Offline it degrades to the cached
# answer and passes with a loud banner; `--no-verify` is banned here, so
# a hook that hard-failed on a flaky connection would leave no way to
# commit at all. CI, always online, is the strict authority.
# commit at all. The strict run is local only (CI does not check
# freshness): scripts/check_dependency_freshness.sh --all --strict
- id: dependency-freshness
name: dependencies on newest stable
entry: scripts/check_dependency_freshness.sh

View File

@ -21,7 +21,7 @@ pytest-xdist==3.8.0
# token over the REST endpoint; crdt-sync already pulls requests in, but this
# module imports it itself, so it is declared rather than assumed.
requests==2.34.2
ruff==0.17.5
ruff==0.17.6
sickdays @ git+https://github.com/kuhyx/utils@sickdays-v0.5.5#subdirectory=sickdays
types-requests==2.33.0.20261030
# Direct dependency since the Firebase session stream (_session_stream) catches

View File

@ -11,7 +11,7 @@
#
# Usage:
# scripts/check_dependency_freshness.sh <file> [<file> ...] # pre-commit
# scripts/check_dependency_freshness.sh --all --strict # CI
# scripts/check_dependency_freshness.sh --all --strict # full local run
#
# Exit: 0 current | 1 behind | 2 allowlist wrong | 3 undeterminable (offline)
# ============================================================================