You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by ru...@apache.org on 2026/06/04 16:28:12 UTC
(superset) 01/01: ci: stable required-check anchors for skippable matrix test jobs
This is an automated email from the ASF dual-hosted git repository.
rusackas pushed a commit to branch ci/required-check-shims
in repository https://gitbox.apache.org/repos/asf/superset.git
commit 54e849bec09de87658228fd61ad9db51ab1e7378
Author: Claude Code <no...@anthropic.com>
AuthorDate: Thu Jun 4 09:27:49 2026 -0700
ci: stable required-check anchors for skippable matrix test jobs
unit-tests and test-postgres are matrix jobs gated on change detection
(needs.changes.outputs.python). On a non-Python PR (e.g. a frontend
Dependabot bump) the job is skipped at the job level — which happens before
matrix expansion — so the per-combination contexts `unit-tests (current)`
and `test-postgres (current)` are never produced at all. Branch protection
requires those contexts, so such PRs sit forever on "Expected — Waiting for
status to be reported" and cannot merge.
(Non-matrix gated jobs like test-mysql/test-sqlite don't hit this: a skipped
non-matrix job still publishes its check as "skipped", which counts as
success.)
Add an always-running `*-required` anchor job per matrix job that passes
when the underlying job succeeded or was skipped and fails only on a real
failure, and point the required status checks at those anchors instead of
the matrix-expanded contexts. The expensive jobs stay fully skipped on
unrelated PRs (no wasted service containers); the anchor is a ~5s no-op.
Co-Authored-By: Claude Opus 4.8 <no...@anthropic.com>
---
.asf.yaml | 4 ++--
.../workflows/superset-python-integrationtest.yml | 22 ++++++++++++++++++++++
.github/workflows/superset-python-unittest.yml | 22 ++++++++++++++++++++++
3 files changed, 46 insertions(+), 2 deletions(-)
diff --git a/.asf.yaml b/.asf.yaml
index f2ad36521bf..6c517f69c8f 100644
--- a/.asf.yaml
+++ b/.asf.yaml
@@ -85,11 +85,11 @@ github:
- pre-commit (current)
- pre-commit (previous)
- test-mysql
- - test-postgres (current)
+ - test-postgres-required
- test-postgres-hive
- test-postgres-presto
- test-sqlite
- - unit-tests (current)
+ - unit-tests-required
required_pull_request_reviews:
dismiss_stale_reviews: false
diff --git a/.github/workflows/superset-python-integrationtest.yml b/.github/workflows/superset-python-integrationtest.yml
index dee0165ab05..4cca3d06a48 100644
--- a/.github/workflows/superset-python-integrationtest.yml
+++ b/.github/workflows/superset-python-integrationtest.yml
@@ -222,3 +222,25 @@ jobs:
verbose: true
use_oidc: true
slug: apache/superset
+
+ # Stable required-status-check anchor for the matrix-based test-postgres job.
+ # It is gated on change detection, so on non-Python PRs it is skipped and
+ # never produces its `test-postgres (current)` context (a job-level skip
+ # happens before matrix expansion). This always-running job reports a single
+ # context branch protection can require: it passes when test-postgres
+ # succeeded or was skipped, and fails only on a real failure.
+ test-postgres-required:
+ needs: [changes, test-postgres]
+ if: always()
+ runs-on: ubuntu-24.04
+ timeout-minutes: 5
+ steps:
+ - name: Check test-postgres result
+ env:
+ RESULT: ${{ needs.test-postgres.result }}
+ run: |
+ if [ "$RESULT" != "success" ] && [ "$RESULT" != "skipped" ]; then
+ echo "test-postgres did not pass (result: $RESULT)"
+ exit 1
+ fi
+ echo "test-postgres result: $RESULT"
diff --git a/.github/workflows/superset-python-unittest.yml b/.github/workflows/superset-python-unittest.yml
index 36db4cc239a..3fce08ea400 100644
--- a/.github/workflows/superset-python-unittest.yml
+++ b/.github/workflows/superset-python-unittest.yml
@@ -74,3 +74,25 @@ jobs:
verbose: true
use_oidc: true
slug: apache/superset
+
+ # Stable required-status-check anchor. `unit-tests` is a matrix job gated on
+ # change detection, so on non-Python PRs it is skipped and never produces its
+ # `unit-tests (current)` context (a job-level skip happens before matrix
+ # expansion). This always-running job reports a single context that branch
+ # protection can require: it passes when unit-tests succeeded or was skipped,
+ # and fails only on a real failure.
+ unit-tests-required:
+ needs: [changes, unit-tests]
+ if: always()
+ runs-on: ubuntu-24.04
+ timeout-minutes: 5
+ steps:
+ - name: Check unit-tests result
+ env:
+ RESULT: ${{ needs.unit-tests.result }}
+ run: |
+ if [ "$RESULT" != "success" ] && [ "$RESULT" != "skipped" ]; then
+ echo "unit-tests did not pass (result: $RESULT)"
+ exit 1
+ fi
+ echo "unit-tests result: $RESULT"