30
30
- name : Cache conda packages
31
31
uses : actions/cache@v3
32
32
env :
33
- CACHE_NUMBER : 1 # Increase to reset cache
33
+ CACHE_NUMBER : 3 # Increase to reset cache
34
34
with :
35
35
path : ~/.conda/pkgs
36
36
key :
78
78
- name : Cache conda packages
79
79
uses : actions/cache@v3
80
80
env :
81
- CACHE_NUMBER : 1 # Increase to reset cache
81
+ CACHE_NUMBER : 3 # Increase to reset cache
82
82
with :
83
83
path : /home/runner/conda_pkgs_dir
84
84
key :
@@ -107,7 +107,7 @@ jobs:
107
107
runner : [ubuntu-latest]
108
108
continue-on-error : ${{ matrix.experimental }}
109
109
env :
110
- CHANNELS : -c intel -c defaults --override-channels
110
+ CHANNELS : -c defaults -c intel --override-channels
111
111
112
112
steps :
113
113
- name : Download artifact
@@ -132,15 +132,15 @@ jobs:
132
132
run : |
133
133
CHANNELS="-c $GITHUB_WORKSPACE/channel ${{ env.CHANNELS }}"
134
134
export PACKAGE_VERSION=$(python -c "${VER_SCRIPT1} ${VER_SCRIPT2}")
135
- conda install $PACKAGE_NAME=${PACKAGE_VERSION} python=${{ matrix.python }} $CHANNELS --only-deps --dry-run > lockfile
135
+ conda create -n test_dpctl $PACKAGE_NAME=${PACKAGE_VERSION} python=${{ matrix.python }} $CHANNELS --only-deps --dry-run > lockfile
136
136
cat lockfile
137
137
- name : Set pkgs_dirs
138
138
run : |
139
139
echo "pkgs_dirs: [~/.conda/pkgs]" >> ~/.condarc
140
140
- name : Cache conda packages
141
141
uses : actions/cache@v3
142
142
env :
143
- CACHE_NUMBER : 1 # Increase to reset cache
143
+ CACHE_NUMBER : 3 # Increase to reset cache
144
144
with :
145
145
path : ~/.conda/pkgs
146
146
key :
@@ -152,16 +152,20 @@ jobs:
152
152
run : |
153
153
CHANNELS="-c $GITHUB_WORKSPACE/channel ${{ env.CHANNELS }}"
154
154
export PACKAGE_VERSION=$(python -c "${VER_SCRIPT1} ${VER_SCRIPT2}")
155
- conda install $PACKAGE_NAME=${PACKAGE_VERSION} pytest python=${{ matrix.python }} $CHANNELS
155
+ conda create -n test_dpctl $PACKAGE_NAME=${PACKAGE_VERSION} pytest python=${{ matrix.python }} $CHANNELS
156
156
# Test installed packages
157
157
conda list
158
158
- name : Smoke test
159
159
run : |
160
+ . $CONDA/etc/profile.d/conda.sh
161
+ conda activate test_dpctl
160
162
export OCL_ICD_FILENAMES=libintelocl.so
161
163
export SYCL_ENABLE_HOST_DEVICE=1
162
164
python -c "import dpctl; dpctl.lsplatform()"
163
165
- name : Run tests
164
166
run : |
167
+ . $CONDA/etc/profile.d/conda.sh
168
+ conda activate test_dpctl
165
169
# echo "libintelocl.so" | tee /etc/OpenCL/vendors/intel-cpu.icd
166
170
export OCL_ICD_FILENAMES=libintelocl.so
167
171
export SYCL_ENABLE_HOST_DEVICE=1
@@ -179,7 +183,7 @@ jobs:
179
183
runner : [windows-latest]
180
184
continue-on-error : ${{ matrix.experimental }}
181
185
env :
182
- CHANNELS : -c intel -c defaults --override-channels
186
+ CHANNELS : -c defaults -c intel --override-channels
183
187
184
188
steps :
185
189
- name : Download artifact
@@ -215,7 +219,7 @@ jobs:
215
219
- name : Cache conda packages
216
220
uses : actions/cache@v3
217
221
env :
218
- CACHE_NUMBER : 1 # Increase to reset cache
222
+ CACHE_NUMBER : 3 # Increase to reset cache
219
223
with :
220
224
path : /home/runner/conda_pkgs_dir
221
225
key :
@@ -342,7 +346,7 @@ jobs:
342
346
runner : [ubuntu-latest]
343
347
continue-on-error : ${{ matrix.experimental }}
344
348
env :
345
- CHANNELS : -c intel -c defaults --override-channels
349
+ CHANNELS : -c defaults -c intel --override-channels
346
350
347
351
steps :
348
352
- name : Install conda-build
@@ -361,10 +365,12 @@ jobs:
361
365
- name : Create conda channel
362
366
run : |
363
367
mkdir -p $GITHUB_WORKSPACE/channel/linux-64
364
- mv ${PACKAGE_NAME}-*.tar.bz2 $GITHUB_WORKSPACE/channel/linux-64
365
- conda index $GITHUB_WORKSPACE/channel
368
+ conda index $GITHUB_WORKSPACE/channel || exit 1
369
+ mv ${PACKAGE_NAME}-*.tar.bz2 $GITHUB_WORKSPACE/channel/linux-64 || exit 1
370
+ conda index $GITHUB_WORKSPACE/channel || exit 1
366
371
# Test channel
367
- conda search $PACKAGE_NAME -c $GITHUB_WORKSPACE/channel --override-channels
372
+ conda search $PACKAGE_NAME -c $GITHUB_WORKSPACE/channel --override-channels --info --json > $GITHUB_WORKSPACE/ver.json
373
+ cat ver.json
368
374
- name : Collect dependencies
369
375
run : |
370
376
CHANNELS="-c $GITHUB_WORKSPACE/channel ${{ env.CHANNELS }}"
@@ -375,7 +381,7 @@ jobs:
375
381
- name : Cache conda packages
376
382
uses : actions/cache@v3
377
383
env :
378
- CACHE_NUMBER : 1 # Increase to reset cache
384
+ CACHE_NUMBER : 3 # Increase to reset cache
379
385
with :
380
386
path : ~/.conda/pkgs
381
387
key :
@@ -387,7 +393,7 @@ jobs:
387
393
shell : bash -l {0}
388
394
run : |
389
395
CHANNELS="${{ env.CHANNELS }}"
390
- source $CONDA/etc/profile.d/conda.sh
396
+ . $CONDA/etc/profile.d/conda.sh
391
397
conda create -n examples -y pytest python=${{ matrix.python }} $CHANNELS
392
398
conda install -n examples -y cmake">=3.22" $CHANNELS || exit 1
393
399
conda install -n examples -y ninja $CHANNELS || exit 1
@@ -398,9 +404,9 @@ jobs:
398
404
shell : bash -l {0}
399
405
run : |
400
406
source $CONDA/etc/profile.d/conda.sh
401
- conda activate
402
- CHANNELS="-c $GITHUB_WORKSPACE/channel -c dppy/label/dev -c intel --override-channels"
403
- conda install -n examples -y $CHANNELS numpy dpctl dpnp || exit 1
407
+ CHANNELS="-c $GITHUB_WORKSPACE/channel -c dppy/label/dev -c intel -c defaults --override-channels"
408
+ export PACKAGE_VERSION=$(python -c "${VER_SCRIPT1} ${VER_SCRIPT2}")
409
+ conda install -n examples -y ${ CHANNELS} dpctl=${PACKAGE_VERSION} dpnp">=0.10.1" || exit 1
404
410
- name : Build and run examples with native extensions
405
411
shell : bash -l {0}
406
412
run : |
0 commit comments