Skip to content

Commit

Permalink
Debugging conda mamba env setup pt 7
Browse files Browse the repository at this point in the history
Trying three different ways of installing mamba/micromamba,
in the hope that at least one of them currenlty works.
This is such a shitshow.
  • Loading branch information
lczech committed Jul 10, 2024
1 parent 06e0880 commit 98bc6c3
Showing 1 changed file with 36 additions and 27 deletions.
63 changes: 36 additions & 27 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ jobs:
os:
- ubuntu-latest
# - macos-latest
# - ubuntu-22.04
# - ubuntu-20.04
# - ubuntu-22.04
# - ubuntu-24.04
# - macos-12
# - macos-11
# - macos-13
# - macos-14

# Test cases as listed in test/cases/*.txt
# We update them automatically when running the test/run.sh script, so that each time
Expand Down Expand Up @@ -104,13 +106,15 @@ jobs:
# For now, we just test the base case to see if it's generally working.
# This repeats one of the Ubuntu runs for the base case, but that's okay
# to keep it future proof when the default ubuntu-latest changes.
- os: ubuntu-20.04
case: base
- os: ubuntu-22.04
case: base
- os: ubuntu-20.04
- os: ubuntu-24.04
case: base
- os: macos-12
case: base
- os: macos-11
- os: macos-13
case: base

# -------------------------------------------------------
Expand All @@ -122,27 +126,30 @@ jobs:
uses: actions/checkout@v4

- name: Setup Conda
uses: conda-incubator/setup-miniconda@v3.0.3
uses: conda-incubator/setup-miniconda@v3.0.4
with:
# We need mamba here already, otherwise we run into
# https://github.com/conda-incubator/setup-miniconda/issues/262
# mamba-version: "*"
# channels: conda-forge
# We need to replace the above, at least for now, due to instabilities in the action,
mamba-version: "*"
python-version: 3.12
channels: conda-forge,defaults
channel-priority: true
use-mamba: true
environment-file: envs/grenepipe.yaml
activate-environment: grenepipe

# We might need to replace the above, at least for now, due to instabilities in the action,
# see https://github.com/conda-incubator/setup-miniconda/issues/274#issue-1531425010
# If that changes again in the future, also change it below in the other jobs.
# miniforge-variant: Mambaforge
miniforge-version: latest
# miniforge-version: latest
# New workaround suggestion:
# https://github.com/conda-incubator/setup-miniconda/issues/292#issuecomment-1767669652
# Why is this stuff so broken all the time?
use-mamba: true
channels: conda-forge
environment-file: envs/grenepipe.yaml
activate-environment: grenepipe

# Manually create the conda env.
# Not needed at the moment, as the above setup works fine. Keeping this here for reference.
# Not needed at the moment, as the above setup works (if it works).
# Keeping this here for reference.
# - name: Install Conda Env
# shell: bash -el {0}
# run: |
Expand Down Expand Up @@ -223,10 +230,10 @@ jobs:
# mamba-version: "*"
# channels: conda-forge
# Need to use a different setup to get mamba to work, see above.
# miniforge-variant: Mambaforge
miniforge-variant: Mambaforge
miniforge-version: latest
use-mamba: true
channels: conda-forge
channels: conda-forge,defaults
environment-file: envs/grenepipe.yaml
activate-environment: grenepipe

Expand Down Expand Up @@ -266,16 +273,19 @@ jobs:

matrix:
os:
- ubuntu-22.04
- ubuntu-20.04
- ubuntu-22.04
- ubuntu-24.04
- macos-12
- macos-11
- macos-13
- macos-14

installer:
# Conda is just waaaay to slow... some runs even exceed the GitHub Actions
# max runtime of 6h, so we have to deactivate it for now.
# - conda
- mamba
- micromamba

# -------------------------------------------------------
# Steps
Expand All @@ -286,19 +296,18 @@ jobs:
uses: actions/checkout@v4

- name: Setup Conda
uses: conda-incubator/setup-miniconda@v3.0.3
uses: mamba-org/setup-micromamba@v1.9.0
with:
# mamba-version: "*"
# channels: conda-forge
# Need to use a different setup now to get mamba to work, see above.
# miniforge-variant: Mambaforge
miniforge-version: latest
use-mamba: true
channels: conda-forge
# Trying another installer, see if that one finally works...
# Any version from https://github.com/mamba-org/micromamba-releases
micromamba-version: '1.5.8-0'
environment-file: envs/grenepipe.yaml
activate-environment: grenepipe
environment-name: grenepipe
init-shell: bash
post-cleanup: 'all'

- name: Install Envs
shell: bash -el {0}
run: |
cd envs
for env in `ls *.yaml` ; do
Expand Down

0 comments on commit 98bc6c3

Please sign in to comment.