@@ -62,10 +62,16 @@ jobs:
6262
6363 - name : Read build CTK version
6464 run : |
65+ VERSION_KEY='.cuda.build.version'
66+ BINDINGS_COMPONENT_DIR='cuda_bindings'
67+ if [[ "${{ inputs.is-release }}" == "true" && "${{ inputs.git-tag }}" == v12.9.* ]]; then
68+ VERSION_KEY='.cuda.prev_build.version'
69+ BINDINGS_COMPONENT_DIR='cuda_bindings_12'
70+ fi
6571 if [[ -f ci/versions.yml ]]; then
66- BUILD_CTK_VER=$(yq '.cuda.build.version' ci/versions.yml)
72+ BUILD_CTK_VER=$(yq "${VERSION_KEY}" ci/versions.yml)
6773 elif [[ -f ci/versions.json ]]; then
68- BUILD_CTK_VER=$(jq -r '.cuda.build.version' ci/versions.json)
74+ BUILD_CTK_VER=$(jq -r "${VERSION_KEY}" ci/versions.json)
6975 else
7076 echo "error: cannot find ci/versions.yml or ci/versions.json" >&2
7177 exit 1
7581 exit 1
7682 fi
7783 echo "BUILD_CTK_VER=${BUILD_CTK_VER}" >> "$GITHUB_ENV"
84+ echo "BINDINGS_COMPONENT_DIR=${BINDINGS_COMPONENT_DIR}" >> "$GITHUB_ENV"
7885
7986 # TODO: This workflow runs on GH-hosted runner and cannot use the proxy cache
8087
@@ -126,22 +133,26 @@ jobs:
126133 CUDA_BINDINGS_ARTIFACT_BASENAME="cuda-bindings-python${PYTHON_VERSION_FORMATTED}-cuda${BUILD_CTK_VER}-linux-64"
127134 echo "CUDA_BINDINGS_ARTIFACT_BASENAME=${CUDA_BINDINGS_ARTIFACT_BASENAME}" >> $GITHUB_ENV
128135 echo "CUDA_BINDINGS_ARTIFACT_NAME=${CUDA_BINDINGS_ARTIFACT_BASENAME}-${FILE_HASH}" >> $GITHUB_ENV
129- echo "CUDA_BINDINGS_ARTIFACTS_DIR=$(realpath "$REPO_DIR/cuda_bindings/dist")" >> $GITHUB_ENV
136+ echo "CUDA_BINDINGS_ARTIFACTS_DIR=$(realpath "$REPO_DIR/${BINDINGS_COMPONENT_DIR}/dist")" >> $GITHUB_ENV
137+ echo "CUDA_PYTHON_ARTIFACT_NAME=cuda-python-wheel-cuda${BUILD_CTK_VER}" >> $GITHUB_ENV
130138
131139 - name : Download cuda-python build artifacts
140+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-python' }}
132141 uses : actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
133142 with :
134- name : cuda-python-wheel
143+ name : ${{ env.CUDA_PYTHON_ARTIFACT_NAME }}
135144 path : .
136145 run-id : ${{ inputs.run-id }}
137146 github-token : ${{ github.token }}
138147
139148 - name : Display structure of downloaded cuda-python artifacts
149+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-python' }}
140150 run : |
141151 pwd
142152 ls -lahR .
143153
144154 - name : Download cuda-pathfinder build artifacts
155+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-pathfinder' || inputs.component == 'cuda-core' }}
145156 uses : actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
146157 with :
147158 name : cuda-pathfinder-wheel
@@ -150,6 +161,7 @@ jobs:
150161 github-token : ${{ github.token }}
151162
152163 - name : Display structure of downloaded cuda-pathfinder artifacts
164+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-pathfinder' || inputs.component == 'cuda-core' }}
153165 run : |
154166 pwd
155167 ls -lahR cuda_pathfinder
@@ -162,7 +174,7 @@ jobs:
162174 path : ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}
163175
164176 - name : Download cuda.bindings build artifacts
165- if : ${{ inputs.is-release }}
177+ if : ${{ inputs.is-release && (inputs.component == 'all' || inputs.component == 'cuda-bindings' || inputs.component == 'cuda-core') }}
166178 uses : actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
167179 with :
168180 pattern : ${{ env.CUDA_BINDINGS_ARTIFACT_NAME }}
@@ -172,6 +184,7 @@ jobs:
172184 github-token : ${{ github.token }}
173185
174186 - name : Display structure of downloaded cuda.bindings artifacts
187+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-bindings' || inputs.component == 'cuda-core' }}
175188 run : |
176189 pwd
177190 ls -lahR $CUDA_BINDINGS_ARTIFACTS_DIR
@@ -184,7 +197,7 @@ jobs:
184197 path : ${{ env.CUDA_CORE_ARTIFACTS_DIR }}
185198
186199 - name : Download cuda.core build artifacts
187- if : ${{ inputs.is-release }}
200+ if : ${{ inputs.is-release && (inputs.component == 'all' || inputs.component == 'cuda-core') }}
188201 uses : actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
189202 with :
190203 pattern : ${{ env.CUDA_CORE_ARTIFACT_NAME }}
@@ -194,26 +207,37 @@ jobs:
194207 github-token : ${{ github.token }}
195208
196209 - name : Display structure of downloaded cuda.core build artifacts
210+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-core' }}
197211 run : |
198212 pwd
199213 ls -lahR $CUDA_CORE_ARTIFACTS_DIR
200214
201- - name : Install all packages
215+ - name : Install cuda-pathfinder
216+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-pathfinder' || inputs.component == 'cuda-core' }}
202217 run : |
203218 pushd cuda_pathfinder
204219 pip install *.whl
205220 popd
206221
222+ - name : Install cuda.bindings
223+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-bindings' || inputs.component == 'cuda-core' }}
224+ run : |
207225 pushd "${CUDA_BINDINGS_ARTIFACTS_DIR}"
208226 pip install *.whl
209227 popd
210228
229+ - name : Install cuda.core
230+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-core' }}
231+ run : |
211232 pushd "${CUDA_CORE_ARTIFACTS_DIR}"
212233 pip install *.whl
213234 popd
214235
215- # Subpackages are already installed from CI artifacts above.
216- # --no-deps avoids re-resolving cuda-core from PyPI during tag releases.
236+ - name : Install cuda-python
237+ if : ${{ !inputs.is-release || inputs.component == 'all' || inputs.component == 'cuda-python' }}
238+ run : |
239+ # Documentation builds do not exercise runtime dependencies.
240+ # --no-deps also avoids resolving artifacts absent from focused tag runs.
217241 pip install --no-deps cuda_python*.whl
218242
219243 # This step sets the PR_NUMBER/BUILD_LATEST/BUILD_PREVIEW env vars.
@@ -246,6 +270,9 @@ jobs:
246270 if : ${{ inputs.component != 'all' }}
247271 run : |
248272 COMPONENT=$(echo "${{ inputs.component }}" | tr '-' '_')
273+ if [[ "${{ inputs.component }}" == "cuda-bindings" ]]; then
274+ COMPONENT="${BINDINGS_COMPONENT_DIR}"
275+ fi
249276 pushd ${COMPONENT}/docs/
250277 if [[ "${{ inputs.is-release }}" == "false" ]]; then
251278 ./build_docs.sh latest-only
0 commit comments