Skip to content

Commit 41c48b4

Browse files
Merge pull request #1030 from IntelPython/add-win-py310
2 parents c0e9f69 + 81a9ef8 commit 41c48b4

File tree

1 file changed

+21
-20
lines changed

1 file changed

+21
-20
lines changed

.github/workflows/conda-package.yml

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363

6464
strategy:
6565
matrix:
66-
python: ['3.8', '3.9']
66+
python: ['3.8', '3.9', '3.10']
6767
env:
6868
conda-bld: C:\Miniconda\conda-bld\win-64\
6969
steps:
@@ -73,6 +73,7 @@ jobs:
7373
- uses: conda-incubator/setup-miniconda@v2
7474
with:
7575
auto-activate-base: true
76+
conda-build-version: "*"
7677
activate-environment: ""
7778

7879
- name: Cache conda packages
@@ -86,8 +87,6 @@ jobs:
8687
restore-keys: |
8788
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-python-${{ matrix.python }}-
8889
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-
89-
- name: Install conda-build
90-
run: conda install conda-build
9190
- name: Build conda package
9291
run: conda build --no-test --python ${{ matrix.python }} -c intel -c main --override-channels conda-recipe
9392
- name: Upload artifact
@@ -177,7 +176,7 @@ jobs:
177176

178177
strategy:
179178
matrix:
180-
python: ['3.8', '3.9']
179+
python: ['3.8', '3.9', '3.10']
181180
experimental: [false]
182181
runner: [windows-latest]
183182
continue-on-error: ${{ matrix.experimental }}
@@ -194,39 +193,39 @@ jobs:
194193
with:
195194
use-only-tar-bz2: true
196195
auto-update-conda: true
196+
conda-build-version: '*'
197197
miniconda-version: 'latest'
198198
activate-environment: "dpctl_test"
199-
- name: Install conda-build
200-
shell: cmd /C CALL {0}
201-
# Needed to be able to run conda index
202-
run: conda install conda-build
203-
- name: Create conda channel
199+
- name: Create conda channel with the artifact bit
204200
shell: cmd /C CALL {0}
205201
run: |
206202
echo ${{ env.workdir }}
207203
mkdir ${{ env.workdir }}\channel\win-64
208204
move ${{ env.PACKAGE_NAME }}-*.tar.bz2 ${{ env.workdir }}\channel\win-64
209-
conda index ${{ env.workdir }}/channel
210-
# Test channel
205+
dir ${{ env.workdir }}\channel\win-64
206+
- name: Index the channel
207+
shell: cmd /C CALL {0}
208+
run: conda index ${{ env.workdir }}\channel
209+
210+
- name: Dump dpctl version info from created channel into ver.json
211+
shell: cmd /C CALL {0}
212+
run: |
211213
conda search ${{ env.PACKAGE_NAME }} -c ${{ env.workdir }}/channel --override-channels --info --json > ${{ env.workdir }}\ver.json
212-
type ${{ env.workdir }}\ver.json
214+
- name: Output content of produced ver.json
215+
run: Get-Content -Path ${{ env.workdir }}\ver.json
213216
- name: Collect dependencies
214217
shell: cmd /C CALL {0}
215218
run: |
216-
@ECHO ON
217-
if not exist ver.json (
219+
IF NOT EXIST ver.json (
218220
copy /Y ${{ env.workdir }}\ver.json .
219221
)
220-
set "SCRIPT=%VER_SCRIPT1% %VER_SCRIPT2%"
222+
SET "SCRIPT=%VER_SCRIPT1% %VER_SCRIPT2%"
221223
FOR /F "tokens=* USEBACKQ" %%F IN (`python -c "%SCRIPT%"`) DO (
222224
SET PACKAGE_VERSION=%%F
223225
)
224226
conda install ${{ env.PACKAGE_NAME }}=%PACKAGE_VERSION% python=${{ matrix.python }} -c ${{ env.workdir }}/channel ${{ env.CHANNELS }} --only-deps --dry-run > lockfile
225227
- name: Display lockfile content
226-
shell: cmd /C CALL {0}
227-
run: |
228-
echo "Outputting content of lockfile:"
229-
type lockfile
228+
run: Get-Content -Path .\lockfile
230229
- name: Cache conda packages
231230
uses: actions/cache@v3
232231
env:
@@ -245,7 +244,9 @@ jobs:
245244
shell: cmd /C CALL {0}
246245
run: |
247246
@ECHO ON
248-
copy /Y ${{ env.workdir }}\ver.json .
247+
IF NOT EXIST ver.json (
248+
copy /Y ${{ env.workdir }}\ver.json .
249+
)
249250
set "SCRIPT=%VER_SCRIPT1% %VER_SCRIPT2%"
250251
FOR /F "tokens=* USEBACKQ" %%F IN (`python -c "%SCRIPT%"`) DO (
251252
SET PACKAGE_VERSION=%%F

0 commit comments

Comments
 (0)