Skip to content

Commit 3e55058

Browse files
committed
Move the GPU probe into a seperate step to reduce likelyhood of a collision between docker run cleanup and restart.
1 parent e71d4e5 commit 3e55058

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/pytest-gpu.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,16 @@ jobs:
103103
- name: Export CODECOV token
104104
run: echo "CODECOV_TOKEN=${{ secrets.CODECOV_TOKEN }}" >> "$GITHUB_ENV"
105105

106+
- name: Probe gpu
107+
run: |
108+
# Run a simple driver cmd first (nvidia-smi / rocm-smi)
109+
docker run ${{ matrix.flags }} "${DOCKER_IMAGE}" ${{ matrix.test_drive_cmd }}
110+
106111
- name: Test with pytest
107112
run: |
108113
# Run a simple driver cmd first (nvidia-smi / rocm-smi)
109114
ci_env=$(bash <(curl -s https://codecov.io/env))
110115
111-
docker run ${{ matrix.flags }} "${DOCKER_IMAGE}" ${{ matrix.test_drive_cmd }}
112-
113116
docker run ${{ matrix.flags }} $ci_env -e CI=true "${DOCKER_IMAGE}" \
114117
pytest --cov --cov-config=.coveragerc --cov-report=xml ${{ matrix.test_files }}
115118

0 commit comments

Comments
 (0)