From 3937ea7a3ba4bf52a7754420ea7011f96a715e41 Mon Sep 17 00:00:00 2001 From: Ruben van der Linde Date: Tue, 4 Aug 2026 21:16:53 +0200 Subject: [PATCH 1/2] fix(quality): the coverage-baseline artifact is a dotfile and was never uploaded update-baseline tells you to close the gate by committing 'the recomputed value attached as the coverage-baseline artifact of this run'. That artifact has never existed: .coverage-baseline is a dotfile and actions/upload-artifact@v4 excludes hidden files by default, then warns rather than fails when the glob matches nothing. The gate asked you to close it with a file it had silently declined to produce. Reproduced on docudesk run 30925609908, where the preceding git diff prints the changed file three lines before the upload reports it missing. --- .github/workflows/quality.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml index 9c5e5ffd3..e109c1f22 100644 --- a/.github/workflows/quality.yml +++ b/.github/workflows/quality.yml @@ -3166,6 +3166,30 @@ jobs: with: name: coverage-baseline path: .coverage-baseline + # ⚠️ REQUIRED, and its absence made this an unclosable gate. + # + # `.coverage-baseline` is a DOTFILE. actions/upload-artifact@v4 + # excludes hidden files by default (`include-hidden-files: false`), + # and when the glob then matches nothing it does not fail — it prints + # + # ##[warning]No files were found with the provided path: + # .coverage-baseline. No artifacts will be uploaded. + # + # and the step still succeeds. So the artifact has NEVER existed, + # while the error message immediately above it says: + # + # Commit the recomputed value (attached as the 'coverage-baseline' + # artifact of this run) in a pull request. + # + # The gate therefore told you to close it using a file it had just + # silently declined to produce. Reproduced on docudesk + # (run 30925609908): the preceding `git --no-pager diff -- + # .coverage-baseline` prints the changed file, proving it is on disk, + # and the upload immediately after reports it as not found. + # + # This is the same shape as the swallowed `git push` this job was + # rewritten to remove — a failure that reads as work having been done. + include-hidden-files: true retention-days: 7 # ── Hydra mechanical gates ────────────────────── From 10c841f476e409339b6521a5f4b5a70ca95d352f Mon Sep 17 00:00:00 2001 From: Ruben van der Linde Date: Tue, 4 Aug 2026 21:30:16 +0200 Subject: [PATCH 2/2] fix(quality): a failing php-quality deleted Coverage Baseline Check update-baseline's if carried no status function, so GitHub wrapped it in an implicit success() over the whole needs closure. phpunit survives a red php-quality because its own if has !cancelled(); update-baseline had no such escape, so a failing PHPMD - a grandparent it does not depend on - removed the coverage ratchet while phpunit itself was green. Measured on procest: five consecutive push runs on development where php-quality failed, phpunit succeeded, and the ratchet reported nothing. Reproduced twice on doriath today. Adds !cancelled() && needs.phpunit.result == 'success', mirroring phpunit. --- .github/workflows/quality.yml | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml index e109c1f22..7cbc777bf 100644 --- a/.github/workflows/quality.yml +++ b/.github/workflows/quality.yml @@ -3119,7 +3119,35 @@ jobs: # ratchet, so this gate is closable by a human via a normal pull request — # it is deliberately not an unclosable gate. update-baseline: - if: ${{ inputs.enable-coverage-guard && github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/development') }} + # ⚠️ `!cancelled() && needs.phpunit.result == 'success'` is load-bearing, and + # its absence deleted this job on every run where PHP Quality was red. + # + # A job condition with no status function is implicitly wrapped in + # `success()`, and that success() is not satisfied by this job's DECLARED + # dependency alone — a failure anywhere in the `needs` closure removes the + # job. `phpunit` sits behind `needs: [php-quality, security]` and survives a + # red php-quality only because its own `if` carries `!cancelled()`. This job + # had no such escape, so a failing PHPMD — a GRANDPARENT it does not depend + # on — silently deleted the coverage ratchet while `phpunit` itself was + # green. + # + # Measured on procest's own history (push runs on development): + # + # run 30896879219 php-quality FAIL phpunit success -> CBC skipped + # run 30895657851 php-quality FAIL phpunit success -> CBC skipped + # run 30887852492 php-quality FAIL phpunit success -> CBC skipped + # run 30882883115 php-quality FAIL phpunit success -> CBC skipped + # run 30876345083 php-quality FAIL phpunit failure -> CBC skipped + # + # Five consecutive runs in which the ratchet reported nothing at all, and + # nothing said so: a skipped job is not a red. Reproduced on doriath twice + # today (run 30925445843 and its re-run) — `steps: []`, started_at == + # completed_at, the shape of a job that never existed. + # + # Being explicit also makes the intent legible: this job needs a SUCCESSFUL + # phpunit, because it downloads that job's coverage artifact. It has no + # opinion about PHPMD. + if: ${{ inputs.enable-coverage-guard && github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/development') && !cancelled() && needs.phpunit.result == 'success' }} runs-on: ubuntu-latest name: "Coverage Baseline Check" needs: phpunit