Skip to content

Commit 61f8d6a

Browse files
cpcloudclaude
andcommitted
fix: set explicit dorny base and decouple cython-test skip
Two fixes from code review: 1. Set `base: main` on dorny/paths-filter so backport PRs targeting non-default branches still diff against main for path detection. 2. Decouple SKIP_CYTHON_TEST from SKIP_BINDINGS_TEST_OVERRIDE. The path-filter override only skips bindings tests; cuda.core Cython tests should still run on core-only PRs. Cython skip is now driven solely by CTK minor-version mismatch. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 7da43b9 commit 61f8d6a

File tree

2 files changed

+15
-11
lines changed

2 files changed

+15
-11
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,11 @@ jobs:
111111
if: ${{ startsWith(github.ref_name, 'pull-request/') }}
112112
uses: dorny/paths-filter@d1c1ffe0248fe513906c8e24db8ea791d46f8590 # v3.0.3
113113
with:
114-
# Compare against the target branch of the PR. When a PR is pushed
115-
# to the synthetic pull-request/<N> ref, dorny/paths-filter falls
116-
# back to the repository default branch unless overridden.
114+
# Explicitly compare against the repository default branch. On push
115+
# events dorny/paths-filter defaults to diffing against the prior
116+
# commit, which is wrong for backport PRs targeting non-default
117+
# branches. Pinning base to main ensures consistent detection.
118+
base: main
117119
filters: |
118120
bindings:
119121
- 'cuda_bindings/**'

ci/tools/env-vars

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -65,18 +65,20 @@ elif [[ "${1}" == "test" ]]; then
6565
SKIP_CYTHON_TEST=1
6666
else
6767
USE_BACKPORT_BINDINGS=0
68+
# Path-filter override only skips bindings tests, NOT cython tests
69+
# for other modules (e.g. cuda.core). Cython skip is driven solely
70+
# by the build/test CTK minor-version mismatch.
6871
if [[ "${SKIP_BINDINGS_TEST_OVERRIDE:-0}" == "1" ]]; then
6972
SKIP_CUDA_BINDINGS_TEST=1
70-
SKIP_CYTHON_TEST=1
7173
else
7274
SKIP_CUDA_BINDINGS_TEST=0
73-
BUILD_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${BUILD_CUDA_VER})"
74-
TEST_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${CUDA_VER})"
75-
if [[ ${BUILD_CUDA_MINOR} != ${TEST_CUDA_MINOR} ]]; then
76-
SKIP_CYTHON_TEST=1
77-
else
78-
SKIP_CYTHON_TEST=0
79-
fi
75+
fi
76+
BUILD_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${BUILD_CUDA_VER})"
77+
TEST_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${CUDA_VER})"
78+
if [[ ${BUILD_CUDA_MINOR} != ${TEST_CUDA_MINOR} ]]; then
79+
SKIP_CYTHON_TEST=1
80+
else
81+
SKIP_CYTHON_TEST=0
8082
fi
8183
fi
8284
# We don't test compute-sanitizer on CTK<12 because backporting fixes is too much effort

0 commit comments

Comments
 (0)