Skip to content

Commit

Permalink
Fixing release workflow, again.
Browse files Browse the repository at this point in the history
Pin down conda-build<25 to work around internal artifact extention
rename from .tar.bz2 to .conda in `setuptools-conda`

Adds an anaconda test label for release candidates, which prevents people
from auto-installing them via conda.

Ensure artifact uploads fail if files are not found.
  • Loading branch information
dihm committed Feb 27, 2025
1 parent 29cdf95 commit 08b68db
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/build_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ jobs:
with:
name: dist
path: ./dist
if-no-files-found: error

- name: Set Variables for Conda Build
shell: bash
Expand All @@ -69,14 +70,15 @@ jobs:
- name: Conda package (Unix)
shell: bash -l {0}
run: |
conda install -c labscript-suite setuptools-conda
conda install -c labscript-suite setuptools-conda "conda-build<25"
setuptools-conda build $CONDA_BUILD_ARGS .
- name: Upload Artifact (conda)
uses: actions/upload-artifact@v4
with:
name: conda_packages
path: ./conda_packages
if-no-files-found: error

github-release:
name: Github Release
Expand Down Expand Up @@ -179,8 +181,20 @@ jobs:
shell: bash -l {0}
run: conda install anaconda-client

- name: Publish to Test Anaconda channel
shell: bash -l {0}
if: contains(github.event.ref, 'rc')
run: |
anaconda \
--token ${{ secrets.ANACONDA_API_TOKEN }} \
upload \
--user $ANACONDA_USER \
--label test \
conda_packages/*/*
- name: Publish to Anaconda channel
shell: bash -l {0}
if: contains(github.event.ref, 'rc') != true
run: |
anaconda \
--token ${{ secrets.ANACONDA_API_TOKEN }} \
Expand Down

0 comments on commit 08b68db

Please sign in to comment.