diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2cfd95de..34a1232b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -57,18 +57,15 @@ jobs: # 0.1.12 is still on crates.io, so nothing broke when the crate was # deleted from source; this is the last consumer to move off it. # - # Pinned to a chuzz revision that has a published host (0.1.40). The - # previous pin predated the releases, so every run compiled that old - # source against today's registry, and it stopped compiling once its - # unlocked dependencies moved on (tokio features, blitz-control-protocol - # 0.5.3): every PR here went red on a browser build, not on this code. + # Unpinned, as every site's QA is: `@master` downloads the released + # chuzz-headless and installs the newest ps-qa 0.7. A pinned revision + # builds old source against today's registry and stops compiling once + # its unlocked dependencies move on. - name: Headless browser host id: qa - uses: pathscale/chuzz/.github/actions/headless-host@094d77b6f28f78ffcdc20b8b19e160ee6c4992ee + uses: pathscale/chuzz/.github/actions/headless-host@master with: token: ${{ secrets.SIBLING_REPOS_TOKEN }} - chuzz-ref: 094d77b6f28f78ffcdc20b8b19e160ee6c4992ee - ps-qa-version: =0.7.3 - name: Install Dependencies run: bun install --no-save diff --git a/tests/qa-harness/README.md b/tests/qa-harness/README.md index 6573a61a..3539555d 100644 --- a/tests/qa-harness/README.md +++ b/tests/qa-harness/README.md @@ -49,8 +49,8 @@ cargo build --release --manifest-path ../chuzz/Cargo.toml --bin chuzz-headless \ QA_HOST=../chuzz/target/release/chuzz-headless bash tests/qa-harness/run-all.sh ``` -`QA_PS_QA` does the same for a local ps-qa. Release runs use the reviewed exact -version 0.7.3 so a driver update cannot silently change the result. The script +`QA_PS_QA` does the same for a local ps-qa. The harness takes ps-qa `^0.7.3`: a +driver older than 0.7.3 is refused as stale, and any later 0.7 patch runs. The script refuses stale bundles unless `QA_ALLOW_STALE=1` is explicitly set. Linux rendered QA needs fontconfig development files and an installed font such as DejaVu; the shared CI host action installs both. Release verification uses `QA_PROFILE=full`. diff --git a/tests/qa-harness/run-all.sh b/tests/qa-harness/run-all.sh index bface499..6fa4c234 100755 --- a/tests/qa-harness/run-all.sh +++ b/tests/qa-harness/run-all.sh @@ -65,16 +65,22 @@ fi # ignored entirely. Measured: three components "failed" against a driver eight # days stale, and all three passed the moment the current one ran. # -# The driver and host use the shared control protocol from this release. -readonly PS_QA_VERSION="0.7.3" +# The driver and host use the shared control protocol from 0.7.3, so the floor +# is that release and the range is its caret: any later 0.7.x. A driver older +# than the floor is the stale one this check exists to catch; a newer patch is +# what `cargo install ps-qa --version "^0.7"` gives CI, and refusing it failed +# every run the day 0.7.4 was published. +readonly PS_QA_MIN="0.7.3" ps_qa_version="$("$PS_QA" --version 2>/dev/null | awk '{ print $2 }')" if [[ -z "$ps_qa_version" ]]; then echo "$PS_QA does not report a version; it is too old to sweep with" >&2 exit 1 fi -if [[ "$ps_qa_version" != "$PS_QA_VERSION" ]]; then - echo "ps-qa $ps_qa_version is not the reviewed $PS_QA_VERSION this harness requires." >&2 - echo " cargo install ps-qa --version '=$PS_QA_VERSION'" >&2 +IFS=. read -r qa_major qa_minor qa_patch <<<"${ps_qa_version%%[-+]*}" +IFS=. read -r min_major min_minor min_patch <<<"$PS_QA_MIN" +if [[ "$qa_major" != "$min_major" || "$qa_minor" != "$min_minor" || "$qa_patch" -lt "$min_patch" ]]; then + echo "ps-qa $ps_qa_version is outside ^$PS_QA_MIN, which this harness requires." >&2 + echo " cargo install ps-qa --version '^$PS_QA_MIN'" >&2 echo " (or set QA_PS_QA to a build, which is what to do when changing the driver)" >&2 exit 1 fi