From 442ad85e95a2953ce306c6767a23bd0fba4d3d70 Mon Sep 17 00:00:00 2001 From: Henry Webel Date: Mon, 7 Oct 2024 10:53:44 +0200 Subject: [PATCH] :construction: switch mamba installation - see if snakemake envs are somehow cached --- .github/workflows/ci.yaml | 50 +++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 7e16f5b60..8bbbac458 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -25,26 +25,34 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 - - name: Set up Miniconda - # ! change action https://github.com/mamba-org/setup-micromamba - uses: conda-incubator/setup-miniconda@v3 - with: - miniforge-variant: Mambaforge - # miniforge-version: latest - use-mamba: true - channel-priority: disabled - python-version: ${{ matrix.python-version }} + # - name: Set up Miniconda + # # ! change action https://github.com/mamba-org/setup-micromamba + # uses: conda-incubator/setup-miniconda@v3 + # with: + # miniforge-variant: Mambaforge + # # miniforge-version: latest + # use-mamba: true + # channel-priority: disabled + # python-version: ${{ matrix.python-version }} + # environment-file: snakemake_env.yml + # activate-environment: snakemake + # auto-activate-base: true + # # auto-update-conda: true + - uses: mamba-org/setup-micromamba@v1 + with: + micromamba-version: 'latest' # any version from https://github.com/mamba-org/micromamba-releases environment-file: snakemake_env.yml - activate-environment: snakemake - auto-activate-base: true - # auto-update-conda: true - - name: inspect-conda-environment - run: | - conda info - conda list - conda env export --from-history --no-builds > environment.yml - conda env export --no-builds - conda env export --no-builds > environment_w_versions.yml + init-shell: >- + bash + cache-environment: true + post-cleanup: 'all' + # - name: inspect-conda-environment + # run: | + # conda info + # conda list + # conda env export --from-history --no-builds > environment.yml + # conda env export --no-builds + # conda env export --no-builds > environment_w_versions.yml # - name: test-r-kernel-imports # run: | # Rscript -e "library(stringi)" @@ -54,6 +62,8 @@ jobs: run: | cd project snakemake -p -c1 --configfile config/single_dev_dataset/example/config.yaml --use-conda -n + - name: Show current files in conda snakemake folder + run: ls -l /Users/runner/work/pimms/pimms/project/.snakemake/conda/ - name: Run demo workflow (integration test) continue-on-error: true run: | @@ -141,4 +151,4 @@ jobs: - uses: pypa/gh-action-pypi-publish@release/v1 with: user: __token__ - password: ${{ secrets.PYPI_API_TOKEN }} \ No newline at end of file + password: ${{ secrets.PYPI_API_TOKEN }}