From cadcae970927b535730fc1f619f9592d6b1c0a4b Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 19:48:32 +0200 Subject: [PATCH 01/23] Switch to setup-micromamba --- .github/workflows/conda_canary.yml | 13 +++++---- .github/workflows/linters.yml | 5 ++-- .github/workflows/main.yml | 47 +++++++++++++++++------------- .github/workflows/static_build.yml | 10 +++---- README.md | 4 +-- 5 files changed, 44 insertions(+), 35 deletions(-) diff --git a/.github/workflows/conda_canary.yml b/.github/workflows/conda_canary.yml index e1a5bcdb43..d6dd3261f9 100644 --- a/.github/workflows/conda_canary.yml +++ b/.github/workflows/conda_canary.yml @@ -25,13 +25,16 @@ jobs: with: path: mamba - name: create mamba build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-name: build_env - environment-file: mamba/mamba/environment-dev.yml - channels: conda-forge,conda-canary/label/dev - channel-priority: flexible - extra-specs: | + environment-file: ./mamba/mamba/environment-dev.yml + condarc: | + channels: + - conda-forge + - conda-canary/label/dev + channel_priority: flexible + create-args: | python=3.10 conda =*+* diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml index c3767b06fe..f25fc576d1 100644 --- a/.github/workflows/linters.yml +++ b/.github/workflows/linters.yml @@ -18,12 +18,11 @@ jobs: steps: - uses: actions/checkout@v3 - name: Install pre-commit - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: false environment-name: linters - channels: conda-forge - extra-specs: pre-commit + create-args: pre-commit - name: Micromamba info shell: bash -el {0} run: | diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2d71713967..4ae949f738 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -21,11 +21,11 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./libmamba/environment-static-dev.yml environment-name: build_env - cache-env: true + cache-environment: true - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -60,11 +60,11 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./libmamba/environment-dev.yml environment-name: build_env - cache-env: true + cache-environment: true - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -103,11 +103,11 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./micromamba/environment-dev.yml environment-name: build_env - cache-env: true + cache-environment: true - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -164,12 +164,12 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./mamba/environment-dev.yml environment-name: build_env - cache-env: true - extra-specs: | + cache-environment: true + create-args: | conda-build python=${{ matrix.python_version }} - uses: hendrikmuhs/ccache-action@main @@ -282,11 +282,12 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env - cache-env: true + cache-environment: true + init-shell: cmd.exe - name: fix up vcpkg recipes shell: python run: | @@ -374,14 +375,17 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./mamba/environment-dev.yml environment-name: build_env - cache-env: true - extra-specs: | + cache-environment: true + create-args: | conda-build curl + init-shell: >- + bash + cmd.exe - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -473,11 +477,12 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./libmamba/environment-dev.yml environment-name: build_env - cache-env: true + cache-environment: true + init-shell: cmd.exe - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -524,11 +529,12 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./micromamba/environment-dev.yml environment-name: build_env - cache-env: true + cache-environment: true + init-shell: cmd.exe - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -596,11 +602,12 @@ jobs: tar -xvf umamba.tar - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./micromamba/environment-dev.yml environment-name: build_env - extra-specs: menuinst + create-args: menuinst + init-shell: powershell - name: micromamba python based tests with pwsh shell: powershell diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 7c376b910b..8f64aeca24 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -37,12 +37,11 @@ jobs: - name: Patch micromamba-feedstock run: | cp ./micromamba/recipe/* micromamba-feedstock/recipe/ - - uses: mamba-org/provision-with-micromamba@main + - uses: mamba-org/setup-micromamba@v1 with: - channels: conda-forge environment-file: false environment-name: mambabuild - extra-specs: boa + create-args: boa - name: Build conda package shell: bash -l {0} run: | @@ -93,11 +92,12 @@ jobs: steps: - uses: actions/checkout@v3 - name: create build environment - uses: mamba-org/provision-with-micromamba@main + uses: mamba-org/setup-micromamba@v1 with: environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env - cache-env: true # this also caches the vcpkg builds + cache-environment: true # this also caches the vcpkg builds + init-shell: cmd.exe - name: fix up vcpkg recipes shell: python run: | diff --git a/README.md b/README.md index 2e32e57bb4..0b98df3bec 100644 --- a/README.md +++ b/README.md @@ -51,9 +51,9 @@ See the [repoquery documentation](https://mamba.readthedocs.io/en/latest/user_gu `micromamba` can be used to install lock files generated by [conda-lock](https://conda.github.io/conda-lock/) without having to install `conda-lock`. Simply invoke e.g. `micromamba create -n my-env -f conda-lock.yml` with an environment lockfile named `*-lock.yml` or `*-lock.yaml`. -### provision-with-micromamba (setup-miniconda replacement) +### setup-micromamba (setup-miniconda replacement) -[provision-with-micromamba](https://github.com/marketplace/actions/provision-with-micromamba) is a replacement for [setup-miniconda](https://github.com/marketplace/actions/setup-miniconda) that uses `micromamba`. +[setup-micromamba](https://github.com/marketplace/actions/setup-micromamba) is a replacement for [setup-miniconda](https://github.com/marketplace/actions/setup-miniconda) that uses `micromamba`. It can significantly reduce your CI setup time by: - Using `micromamba`, which takes around 1 s to install. From f55e36cafcb4e8a5048b27ed820687f85be0133f Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 19:53:00 +0200 Subject: [PATCH 02/23] fix --- .github/workflows/linters.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml index f25fc576d1..ec751176cf 100644 --- a/.github/workflows/linters.yml +++ b/.github/workflows/linters.yml @@ -20,7 +20,6 @@ jobs: - name: Install pre-commit uses: mamba-org/setup-micromamba@v1 with: - environment-file: false environment-name: linters create-args: pre-commit - name: Micromamba info From 33624b4304ec99d6b494a3a722afb882eee6e90a Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 20:29:20 +0200 Subject: [PATCH 03/23] fix --- .github/workflows/static_build.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 8f64aeca24..ad99c988af 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -39,7 +39,6 @@ jobs: cp ./micromamba/recipe/* micromamba-feedstock/recipe/ - uses: mamba-org/setup-micromamba@v1 with: - environment-file: false environment-name: mambabuild create-args: boa - name: Build conda package From b5bcc28ebb0586a89044f9e28a98e7f5e2be7fe3 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 20:43:28 +0200 Subject: [PATCH 04/23] fix --- .github/workflows/static_build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index ad99c988af..046e8d9351 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -119,6 +119,8 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) + env: + MAMBA_ROOT_PREFIX: ~/micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From f9205de030f674c1fe10243e0da853d78614e0e4 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 20:56:55 +0200 Subject: [PATCH 05/23] use micromamba-shell --- .github/workflows/static_build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 046e8d9351..fa474e976e 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -42,12 +42,12 @@ jobs: environment-name: mambabuild create-args: boa - name: Build conda package - shell: bash -l {0} + shell: micromamba-shell {0} run: | conda mambabuild -m micromamba-feedstock/.ci_support/${{ matrix.platform }}_${{ matrix.arch }}_.yaml \ micromamba-feedstock/recipe ${{ matrix.arch != '64' && '--no-test' || '' }} - name: Unpack micromamba package - shell: bash -l {0} + shell: micromamba-shell {0} run: | cd $MAMBA_ROOT_PREFIX/envs/mambabuild/conda-bld/${{ matrix.platform }}-${{ matrix.arch }} tar -xvf micromamba-*.tar.bz2 From 568fd90a6436bad698fe3e9c0f91588d7186fb41 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 20:59:54 +0200 Subject: [PATCH 06/23] condarc env var --- .github/workflows/static_build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index fa474e976e..2bec59f2c9 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -46,6 +46,8 @@ jobs: run: | conda mambabuild -m micromamba-feedstock/.ci_support/${{ matrix.platform }}_${{ matrix.arch }}_.yaml \ micromamba-feedstock/recipe ${{ matrix.arch != '64' && '--no-test' || '' }} + env: + CONDARC: ~/micromamba-bin/.condarc - name: Unpack micromamba package shell: micromamba-shell {0} run: | @@ -53,6 +55,8 @@ jobs: tar -xvf micromamba-*.tar.bz2 mkdir -p ${{ github.workspace }}/artifacts cp bin/micromamba ${{ github.workspace }}/artifacts + env: + CONDARC: ~/micromamba-bin/.condarc - name: Test micromamba on emulated target architecture if: ${{ matrix.arch != '64' && matrix.platform == 'linux' }} uses: uraimo/run-on-arch-action@v2 From b79b1e4c77a199cf14dfb298d05c2a0ad69ca75d Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 21:09:10 +0200 Subject: [PATCH 07/23] create-args: >- --- .github/workflows/conda_canary.yml | 2 +- .github/workflows/main.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/conda_canary.yml b/.github/workflows/conda_canary.yml index d6dd3261f9..d863a072cb 100644 --- a/.github/workflows/conda_canary.yml +++ b/.github/workflows/conda_canary.yml @@ -34,7 +34,7 @@ jobs: - conda-forge - conda-canary/label/dev channel_priority: flexible - create-args: | + create-args: >- python=3.10 conda =*+* diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4ae949f738..e63b74d9b2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -169,7 +169,7 @@ jobs: environment-file: ./mamba/environment-dev.yml environment-name: build_env cache-environment: true - create-args: | + create-args: >- conda-build python=${{ matrix.python_version }} - uses: hendrikmuhs/ccache-action@main @@ -380,7 +380,7 @@ jobs: environment-file: ./mamba/environment-dev.yml environment-name: build_env cache-environment: true - create-args: | + create-args: >- conda-build curl init-shell: >- From 25146a5587c2f65ed82ea904bfe56b727c407be3 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 21:15:01 +0200 Subject: [PATCH 08/23] mamba root prefix --- .github/workflows/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e63b74d9b2..e127e6bde3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -310,6 +310,8 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) + env: + MAMBA_ROOT_PREFIX: ~/micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From bab402c51d16b63b28d2e63ad80173e712b25537 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 21:18:58 +0200 Subject: [PATCH 09/23] fix? --- .github/workflows/main.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e127e6bde3..e672beeef7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -311,7 +311,8 @@ jobs: f.write_text(text) env: - MAMBA_ROOT_PREFIX: ~/micromamba + # TODO: fix this + MAMBA_ROOT_PREFIX: C:\Users\runneradmin\micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From a768ac853c3d71cbcb28f8df8e74f15d7c3a75e1 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Wed, 26 Apr 2023 21:23:52 +0200 Subject: [PATCH 10/23] fix --- .github/workflows/static_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 2bec59f2c9..8128458ea9 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -124,7 +124,7 @@ jobs: f.write_text(text) env: - MAMBA_ROOT_PREFIX: ~/micromamba + MAMBA_ROOT_PREFIX: C:\Users\runneradmin\micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From dad16052762938326520b46c758f5195d1124a5b Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Thu, 27 Apr 2023 08:48:14 +0200 Subject: [PATCH 11/23] removed explicit env vars --- .github/workflows/main.yml | 3 --- .github/workflows/static_build.yml | 6 ------ 2 files changed, 9 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e672beeef7..e63b74d9b2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -310,9 +310,6 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) - env: - # TODO: fix this - MAMBA_ROOT_PREFIX: C:\Users\runneradmin\micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 8128458ea9..4c41e12f43 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -46,8 +46,6 @@ jobs: run: | conda mambabuild -m micromamba-feedstock/.ci_support/${{ matrix.platform }}_${{ matrix.arch }}_.yaml \ micromamba-feedstock/recipe ${{ matrix.arch != '64' && '--no-test' || '' }} - env: - CONDARC: ~/micromamba-bin/.condarc - name: Unpack micromamba package shell: micromamba-shell {0} run: | @@ -55,8 +53,6 @@ jobs: tar -xvf micromamba-*.tar.bz2 mkdir -p ${{ github.workspace }}/artifacts cp bin/micromamba ${{ github.workspace }}/artifacts - env: - CONDARC: ~/micromamba-bin/.condarc - name: Test micromamba on emulated target architecture if: ${{ matrix.arch != '64' && matrix.platform == 'linux' }} uses: uraimo/run-on-arch-action@v2 @@ -123,8 +119,6 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) - env: - MAMBA_ROOT_PREFIX: C:\Users\runneradmin\micromamba - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From fb2ee3efa165a123c17bddd691d7750afc494b82 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Thu, 27 Apr 2023 09:59:28 +0200 Subject: [PATCH 12/23] maybe this helps (think not) --- .github/workflows/main.yml | 102 ++++++++++------------------- .github/workflows/static_build.yml | 4 -- 2 files changed, 34 insertions(+), 72 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e63b74d9b2..4a709e4515 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -33,7 +33,6 @@ jobs: - name: build libmamba-static shell: bash -l {0} run: | - micromamba activate build_env mkdir build cd build cmake .. -DBUILD_LIBMAMBA=ON \ @@ -48,7 +47,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs libmamba_cpp_tests: @@ -74,7 +73,6 @@ jobs: - name: build and run libmamba C++ tests shell: bash -l {0} run: | - micromamba activate build_env mkdir build cd build cmake .. -DBUILD_LIBMAMBA=ON \ @@ -91,7 +89,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs umamba_tests: @@ -150,7 +148,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs mamba_python_tests: @@ -178,13 +176,9 @@ jobs: key: ${{ github.job }}-${{ matrix.os }} restore-keys: | libmamba_static-${{ matrix.os }} - - name: run conda init - shell: bash -l {0} - run: conda init - name: build libmamba Python bindings - shell: bash -l {0} + shell: bash -el {0} run: | - micromamba activate build_env mkdir build cd build cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX \ @@ -198,38 +192,31 @@ jobs: ninja ninja install - name: install libmambapy - shell: bash -l {0} + shell: bash -el {0} run: | - micromamba activate build_env pip install -e ./libmambapy/ --no-deps - name: check libmambapy stubs - shell: bash -l {0} + shell: bash -el {0} run: | pybind11-stubgen libmambapy.bindings python compare_stubs.py libmambapy/libmambapy/__init__.pyi stubs/libmambapy/bindings-stubs/__init__.pyi - name: build cache statistics run: sccache --show-stats - name: install mamba - shell: bash -l {0} - run: | - micromamba activate build_env - pip install ./mamba[test] --no-deps + shell: bash -el {0} + run: pip install ./mamba[test] --no-deps - name: run mamba tests suite - shell: bash -l {0} - run: | - micromamba activate build_env - pytest -v --capture=tee-sys mamba/tests + shell: bash -el {0} + run: pytest -v --capture=tee-sys mamba/tests - name: run mamba create/update tests - shell: bash -l {0} + shell: bash -el {0} run: | - micromamba activate build_env mamba create -n test_env xtensor -c conda-forge -y mamba env create -f mamba/tests/test_env.yml mamba env update -f mamba/tests/update_env.yml - name: run mamba local channel test - shell: bash -l {0} + shell: bash -el {0} run: | - micromamba activate build_env if [ "$RUNNER_OS" == "Linux" ]; then mkdir -p $CONDA_PREFIX/conda-bld/linux-64 wget -P $CONDA_PREFIX/conda-bld/linux-64 https://anaconda.org/conda-forge/xtensor/0.21.8/download/linux-64/xtensor-0.21.8-hc9558a2_0.tar.bz2 @@ -248,9 +235,8 @@ jobs: exit 1 fi - name: Run server auth tests - shell: bash -l {0} -euo pipefail -x + shell: bash -euox -l {0} pipefail run: | - micromamba activate build_env cd mamba/tests if [[ "$(uname -s)" == "Linux" ]]; then @@ -260,17 +246,15 @@ jobs: pip install git+https://github.com/conda/conda-content-trust.git@main ./testserver.sh - - name: Shell init - shell: bash -l {0} -euo pipefail -x - run: | - mamba init + shell: bash -el {0} -euo pipefail -x + run: mamba init - name: Cleanup shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs libmamba_static_win: @@ -313,8 +297,6 @@ jobs: - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% mkdir build if %errorlevel% neq 0 exit /b %errorlevel% cd build @@ -343,8 +325,6 @@ jobs: - name: build libmamba-static shell: cmd /C call {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% cd build if %errorlevel% neq 0 exit /b %errorlevel% cmake .. -DCMAKE_INSTALL_PREFIX=%CONDA_PREFIX%\Library ^ @@ -361,7 +341,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs mamba_python_tests_win: @@ -392,14 +372,9 @@ jobs: key: ${{ github.job }}-${{ matrix.os }} restore-keys: | libmamba_static_win-${{ matrix.os }} - - name: run conda init - shell: bash -l {0} - run: conda init - name: build libmamba Python bindings shell: cmd /C call {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% mkdir build if %errorlevel% neq 0 exit /b %errorlevel% cd build @@ -418,35 +393,33 @@ jobs: ninja install - name: install libmambapy shell: cmd /C call {0} - run: | - call micromamba activate build_env - pip install -e .\libmambapy\ --no-deps + run: pip install -e .\libmambapy\ --no-deps - name: build cache statistics run: sccache --show-stats - name: install mamba - shell: bash -l {0} + shell: bash -el {0} run: | python --version pip install ./mamba[test] --no-deps - name: run mamba tests suite - shell: bash -l {0} + shell: bash -el {0} run: pytest -v --capture=tee-sys mamba/tests - name: Run create command - shell: bash -l {0} + shell: bash -el {0} run: mamba create -n test_env xtensor -c conda-forge -y - name: Run env create command - shell: bash -l {0} + shell: bash -el {0} run: mamba env create -f mamba/tests/test_env.yml - name: Run env update command - shell: bash -l {0} + shell: bash -el {0} run: mamba env update -f mamba/tests/update_env.yml - name: Run local channel checks - shell: bash -l {0} - run: | + shell: bash -el {0} + run: | # this tests the created micromamba binary mkdir -p $CONDA_PREFIX/conda-bld/win-64 echo $PATH - micromamba list - micromamba info + ./micromamba list + ./micromamba info curl --version curl https://anaconda.org/conda-forge/xtensor/0.21.7/download/win-64/xtensor-0.21.7-h7ef1ec2_0.tar.bz2 -L -o $CONDA_PREFIX/conda-bld/win-64/xtensor-0.21.7-h7ef1ec2_0.tar.bz2 curl https://anaconda.org/conda-forge/xtl/0.6.21/download/win-64/xtl-0.6.21-h5362a0b_0.tar.bz2 -L -o $CONDA_PREFIX/conda-bld/win-64/xtl-0.6.21-h5362a0b_0.tar.bz2 @@ -463,7 +436,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs libmamba_cpp_tests_win: @@ -492,8 +465,6 @@ jobs: - name: build and run libmamba C++ tests shell: cmd /C call {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% mkdir build if %errorlevel% neq 0 exit /b %errorlevel% cd build @@ -515,7 +486,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs umamba_tests_win: @@ -534,7 +505,7 @@ jobs: environment-file: ./micromamba/environment-dev.yml environment-name: build_env cache-environment: true - init-shell: cmd.exe + init-shell: cmd.eexe - uses: hendrikmuhs/ccache-action@main with: variant: sccache @@ -544,8 +515,6 @@ jobs: - name: build micromamba shell: cmd /C call {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% mkdir build if %errorlevel% neq 0 exit /b %errorlevel% cd build @@ -561,9 +530,7 @@ jobs: ninja install - name: check that micromamba runs shell: cmd /C call {0} - run: | - call micromamba activate build_env - .\build\micromamba\micromamba.exe --help + run: .\build\micromamba\micromamba.exe --help - name: build cache statistics run: sccache --show-stats - name: tar micromamba artifact @@ -579,7 +546,7 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs umamba_tests_win_cmd: @@ -598,8 +565,7 @@ jobs: - name: untar micromamba artifact shell: bash -l -eo pipefail {0} - run: | - tar -xvf umamba.tar + run: tar -xvf umamba.tar - name: create build environment uses: mamba-org/setup-micromamba@v1 @@ -647,5 +613,5 @@ jobs: shell: bash if: always() run: | - # Do not cache temporary envs with 'cache-env: true' + # Do not cache temporary envs with 'cache-environment: true' rm -rf ~/micromamba*/envs/*/envs diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 4c41e12f43..0cfc0faa16 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -122,8 +122,6 @@ jobs: - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% mkdir build if %errorlevel% neq 0 exit /b %errorlevel% cd build @@ -152,8 +150,6 @@ jobs: - name: build micromamba shell: cmd /C CALL {0} run: | - call micromamba activate build_env - if %errorlevel% neq 0 exit /b %errorlevel% cd build if %errorlevel% neq 0 exit /b %errorlevel% cmake .. ^ From 247bdd12dd377a1bd549721e12b353b35f098028 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Thu, 27 Apr 2023 10:24:22 +0200 Subject: [PATCH 13/23] small update --- .github/workflows/main.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4a709e4515..71e39f88d4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -71,7 +71,7 @@ jobs: restore-keys: | libmamba_static-${{ matrix.os }} - name: build and run libmamba C++ tests - shell: bash -l {0} + shell: bash -el {0} run: | mkdir build cd build @@ -113,9 +113,8 @@ jobs: restore-keys: | libmamba_static-${{ matrix.os }} - name: build micromamba - shell: bash -l {0} + shell: bash -el {0} run: | - micromamba activate build_env mkdir build cd build cmake .. -DBUILD_MICROMAMBA=ON \ @@ -142,7 +141,6 @@ jobs: shell: bash -l -eo pipefail {0} run: | export TEST_MAMBA_EXE=$(pwd)/build/micromamba/micromamba - micromamba activate build_env pytest -v --capture=tee-sys micromamba/tests/ - name: Cleanup shell: bash From 524641760aafc0e3654f3d45c472b34b0f2166d0 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Thu, 27 Apr 2023 11:24:20 +0200 Subject: [PATCH 14/23] Use micromamba-shell --- .github/workflows/conda_canary.yml | 43 +++++------- .github/workflows/linters.yml | 10 +-- .github/workflows/main.yml | 108 ++++++++++++----------------- .github/workflows/static_build.yml | 7 +- 4 files changed, 68 insertions(+), 100 deletions(-) diff --git a/.github/workflows/conda_canary.yml b/.github/workflows/conda_canary.yml index d863a072cb..cfdc0f5f12 100644 --- a/.github/workflows/conda_canary.yml +++ b/.github/workflows/conda_canary.yml @@ -4,6 +4,7 @@ on: workflow_dispatch: schedule: - cron: '0 10 * * 0' + push: # TODO remove permissions: contents: read @@ -15,15 +16,13 @@ concurrency: defaults: run: - shell: bash -el {0} + shell: micromamba-shell {0} jobs: conda_nightly: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - with: - path: mamba - name: create mamba build environment uses: mamba-org/setup-micromamba@v1 with: @@ -36,18 +35,16 @@ jobs: channel_priority: flexible create-args: >- python=3.10 - conda =*+* + conda=*+* # Build Mamba - uses: hendrikmuhs/ccache-action@main with: variant: sccache - key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static-${{ matrix.os }} + key: conda-canary-${{ github.job }} + restore-keys: conda-canary- - name: build libmamba Python bindings run: | - cd mamba mkdir build cd build cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX \ @@ -61,39 +58,35 @@ jobs: ninja ninja install - name: install libmambapy - run: | - cd mamba - pip install -e ./libmambapy/ --no-deps + run: pip install -e ./libmambapy/ --no-deps + working-directory: mamba - name: build cache statistics run: sccache --show-stats - name: install mamba - run: | - cd mamba - pip install ./mamba[test] --no-deps + run: pip install ./mamba[test] --no-deps # Test Mamba with Conda nightly - name: run mamba tests suite - run: | - cd mamba - pytest -v --capture=tee-sys mamba/tests + run: pytest -v --capture=tee-sys mamba/tests - name: run mamba create/update tests run: | - cd mamba mamba create -n test_env xtensor -c conda-forge -y mamba env create -f mamba/tests/test_env.yml mamba env update -f mamba/tests/update_env.yml - - uses: JasonEtco/create-an-issue@1a16035489d05041b9af40b970f02e301c52ffba - if: failure() - with: - filename: mamba/.github/workflows/bot_issue_template.md - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # TODO: uncomment + # - uses: JasonEtco/create-an-issue@1a16035489d05041b9af40b970f02e301c52ffba + # if: failure() + # with: + # filename: .github/workflows/bot_issue_template.md + # env: + # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Cleanup if: always() + shell: bash # no need for micromamba-shell + # Do not cache temporary envs with 'cache-environment: true' run: | - # Do not cache temporary envs with 'cache-env: true' rm -rf $(micromamba info --json | jq -r '."env location"')/envs || true rm -rf ~/tmproot* || true rm -rf $(micromamba info --json | jq -r '."env location"')/conda-build/conda-bld || true diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml index ec751176cf..d5315ff48a 100644 --- a/.github/workflows/linters.yml +++ b/.github/workflows/linters.yml @@ -22,12 +22,6 @@ jobs: with: environment-name: linters create-args: pre-commit - - name: Micromamba info - shell: bash -el {0} - run: | - micromamba info - micromamba list - name: Run all linters - shell: bash -el {0} - run: | - pre-commit run --all-files --verbose --show-diff-on-failure + shell: micromamba-shell {0} + run: pre-commit run --all-files --verbose --show-diff-on-failure diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 71e39f88d4..90e33bdfcd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -46,9 +46,8 @@ jobs: - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs libmamba_cpp_tests: needs: [libmamba_static] @@ -68,8 +67,7 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build and run libmamba C++ tests shell: bash -el {0} run: | @@ -88,9 +86,8 @@ jobs: - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs umamba_tests: needs: [libmamba_static] @@ -110,10 +107,9 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build micromamba - shell: bash -el {0} + shell: micromamba-shell {0} run: | mkdir build cd build @@ -129,25 +125,21 @@ jobs: run: sccache --show-stats - name: install zsh, xonsh, fish and tcsh in linux if: matrix.os == 'ubuntu-latest' - shell: bash -l -eo pipefail {0} - run: | - sudo apt-get install zsh xonsh fish tcsh -y + shell: bash + run: sudo apt-get install zsh xonsh fish tcsh -y - name: install xonsh and fish in mac if: matrix.os == 'macos-latest' - shell: bash -l -eo pipefail {0} - run: | - brew install fish xonsh + run: brew install fish xonsh - name: micromamba python based tests - shell: bash -l -eo pipefail {0} + shell: micromamba-shell {0} run: | export TEST_MAMBA_EXE=$(pwd)/build/micromamba/micromamba pytest -v --capture=tee-sys micromamba/tests/ - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs mamba_python_tests: needs: [libmamba_static] @@ -172,10 +164,9 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build libmamba Python bindings - shell: bash -el {0} + shell: micromamba-shell {0} run: | mkdir build cd build @@ -190,24 +181,23 @@ jobs: ninja ninja install - name: install libmambapy - shell: bash -el {0} - run: | - pip install -e ./libmambapy/ --no-deps + shell: micromamba-shell {0} + run: pip install -e ./libmambapy/ --no-deps - name: check libmambapy stubs - shell: bash -el {0} + shell: micromamba-shell {0} run: | pybind11-stubgen libmambapy.bindings python compare_stubs.py libmambapy/libmambapy/__init__.pyi stubs/libmambapy/bindings-stubs/__init__.pyi - name: build cache statistics run: sccache --show-stats - name: install mamba - shell: bash -el {0} + shell: micromamba-shell {0} run: pip install ./mamba[test] --no-deps - name: run mamba tests suite - shell: bash -el {0} + shell: micromamba-shell {0} run: pytest -v --capture=tee-sys mamba/tests - name: run mamba create/update tests - shell: bash -el {0} + shell: micromamba-shell {0} run: | mamba create -n test_env xtensor -c conda-forge -y mamba env create -f mamba/tests/test_env.yml @@ -225,7 +215,8 @@ jobs: wget -P $CONDA_PREFIX/conda-bld/osx-64 https://anaconda.org/conda-forge/xtl/0.6.21/download/osx-64/xtl-0.6.21-h6516342_0.tar.bz2 fi conda index $CONDA_PREFIX/conda-bld - mamba create -n l_o_cal_test xtensor -c local -c conda-forge -y + + ./mamba create -n l_o_cal_test xtensor -c local -c conda-forge -y conda list -n l_o_cal_test conda list -n l_o_cal_test | tail -n +3 > list.txt @@ -245,15 +236,13 @@ jobs: ./testserver.sh - name: Shell init - shell: bash -el {0} -euo pipefail -x - run: mamba init + shell: micromamba-shell {0} + run: ./mamba init - name: Cleanup - shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs libmamba_static_win: runs-on: ${{ matrix.os }} @@ -336,11 +325,9 @@ jobs: - name: build cache statistics run: sccache --show-stats - name: Cleanup - shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs mamba_python_tests_win: needs: [libmamba_static_win] @@ -368,8 +355,7 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static_win-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build libmamba Python bindings shell: cmd /C call {0} run: | @@ -413,29 +399,29 @@ jobs: run: mamba env update -f mamba/tests/update_env.yml - name: Run local channel checks shell: bash -el {0} - run: | # this tests the created micromamba binary + run: | mkdir -p $CONDA_PREFIX/conda-bld/win-64 echo $PATH - ./micromamba list - ./micromamba info + micromamba list + micromamba info curl --version curl https://anaconda.org/conda-forge/xtensor/0.21.7/download/win-64/xtensor-0.21.7-h7ef1ec2_0.tar.bz2 -L -o $CONDA_PREFIX/conda-bld/win-64/xtensor-0.21.7-h7ef1ec2_0.tar.bz2 curl https://anaconda.org/conda-forge/xtl/0.6.21/download/win-64/xtl-0.6.21-h5362a0b_0.tar.bz2 -L -o $CONDA_PREFIX/conda-bld/win-64/xtl-0.6.21-h5362a0b_0.tar.bz2 conda index $CONDA_PREFIX/conda-bld - mamba create -n l_o_cal_test xtensor -c local -c conda-forge -y - conda list -n l_o_cal_test + ./mamba create -n l_o_cal_test xtensor -c local -c conda-forge -y + + micromamba list -n l_o_cal_test # cut first couple of lines to remove prefix path - conda list -n l_o_cal_test | tail -n +3 > list.txt + micromamba list -n l_o_cal_test | tail -n +3 > list.txt if [ "$(grep -c "local" list.txt)" -ne 2 ]; then exit 1 fi - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs libmamba_cpp_tests_win: needs: [libmamba_static_win] @@ -458,8 +444,7 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static_win-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build and run libmamba C++ tests shell: cmd /C call {0} run: | @@ -483,9 +468,8 @@ jobs: - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs umamba_tests_win: needs: [libmamba_static_win] @@ -508,8 +492,7 @@ jobs: with: variant: sccache key: ${{ github.job }}-${{ matrix.os }} - restore-keys: | - libmamba_static_win-${{ matrix.os }} + restore-keys: libmamba_static-${{ matrix.os }} - name: build micromamba shell: cmd /C call {0} run: | @@ -610,6 +593,5 @@ jobs: - name: Cleanup shell: bash if: always() - run: | - # Do not cache temporary envs with 'cache-environment: true' - rm -rf ~/micromamba*/envs/*/envs + # Do not cache temporary envs with 'cache-environment: true' + run: rm -rf ~/micromamba*/envs/*/envs diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 0cfc0faa16..7cb8bb549d 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -14,7 +14,7 @@ concurrency: jobs: conda-build: - name: "micromamba - ${{ matrix.platform }}-${{ matrix.arch }}" + name: micromamba - ${{ matrix.platform }}-${{ matrix.arch }} runs-on: ${{ matrix.os }} strategy: fail-fast: false @@ -47,9 +47,8 @@ jobs: conda mambabuild -m micromamba-feedstock/.ci_support/${{ matrix.platform }}_${{ matrix.arch }}_.yaml \ micromamba-feedstock/recipe ${{ matrix.arch != '64' && '--no-test' || '' }} - name: Unpack micromamba package - shell: micromamba-shell {0} run: | - cd $MAMBA_ROOT_PREFIX/envs/mambabuild/conda-bld/${{ matrix.platform }}-${{ matrix.arch }} + cd "$MAMBA_ROOT_PREFIX/envs/mambabuild/conda-bld/${{ matrix.platform }}-${{ matrix.arch }}" tar -xvf micromamba-*.tar.bz2 mkdir -p ${{ github.workspace }}/artifacts cp bin/micromamba ${{ github.workspace }}/artifacts @@ -86,7 +85,7 @@ jobs: micromamba_full_static_win: # These build instructions are based on https://github.com/conda-forge/micromamba-feedstock - name: "micromamba - win-64" + name: micromamba - win-64 runs-on: windows-2019 steps: - uses: actions/checkout@v3 From 693b2385cdd2c62424d158194ff773c43469555c Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 12:35:58 +0300 Subject: [PATCH 15/23] add bash --- .github/workflows/static_build.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 7cb8bb549d..420d0c94e7 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -95,7 +95,9 @@ jobs: environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env cache-environment: true # this also caches the vcpkg builds - init-shell: cmd.exe + init-shell: >- # bash is used in the vcpkg part + cmd.exe + bash - name: fix up vcpkg recipes shell: python run: | From d2b1c844d7e0d531a12b20880f657344e2bc5faf Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 12:51:35 +0300 Subject: [PATCH 16/23] debug --- .github/workflows/static_build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 420d0c94e7..b6a25a76e8 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -120,6 +120,9 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) + - run: | + bash.exe -c "echo hallo" + shell: cmd /C CALL {0} - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | From 5ba994752f203b5ab33a29b4685eb40b8dcb0448 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 12:53:44 +0300 Subject: [PATCH 17/23] debug --- .github/workflows/conda_canary.yml | 2 +- .github/workflows/linters.yml | 11 +++++++---- .github/workflows/main.yml | 11 +++++++---- .github/workflows/static_build.yml | 1 + 4 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.github/workflows/conda_canary.yml b/.github/workflows/conda_canary.yml index cfdc0f5f12..fb64bf8185 100644 --- a/.github/workflows/conda_canary.yml +++ b/.github/workflows/conda_canary.yml @@ -4,7 +4,7 @@ on: workflow_dispatch: schedule: - cron: '0 10 * * 0' - push: # TODO remove + # push: # TODO remove permissions: contents: read diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml index d5315ff48a..4db4204f47 100644 --- a/.github/workflows/linters.yml +++ b/.github/workflows/linters.yml @@ -2,11 +2,14 @@ name: Linters (Python, C++) on: push: - branches: - - main - pull_request: branches: - - main + - maadwdwdwd + # push: + # branches: + # - main + # pull_request: + # branches: + # - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 90e33bdfcd..eaf3217adb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -3,10 +3,13 @@ name: CI on: push: branches: - - main - pull_request: - branches: - - main + - admowidjwiojd + # push: + # branches: + # - main + # pull_request: + # branches: + # - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index b6a25a76e8..1bd52f0e01 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -14,6 +14,7 @@ concurrency: jobs: conda-build: + if: false name: micromamba - ${{ matrix.platform }}-${{ matrix.arch }} runs-on: ${{ matrix.os }} strategy: From 630ef8c9e42152b8243f42f0065b6971f242ba92 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 13:01:41 +0300 Subject: [PATCH 18/23] mxschmitt --- .github/workflows/static_build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 1bd52f0e01..4c7595b36c 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -148,6 +148,8 @@ jobs: if %errorlevel% neq 0 exit /b %errorlevel% set CMAKE_PREFIX_PATH=%VCPKG_ROOT%\installed\x64-windows-static\;%CMAKE_PREFIX_PATH% if %errorlevel% neq 0 exit /b %errorlevel% + - uses: mxschmitt/action-tmate@v3 + if: failure() - uses: hendrikmuhs/ccache-action@main with: variant: sccache From dce9306fa09493655cb017987f902bea520d2160 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 13:51:54 +0300 Subject: [PATCH 19/23] powershell --- .github/workflows/static_build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 4c7595b36c..94258704c2 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -99,6 +99,7 @@ jobs: init-shell: >- # bash is used in the vcpkg part cmd.exe bash + powershell - name: fix up vcpkg recipes shell: python run: | From 2209dc9cd260130815b83014cd12dc130245c400 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 13:53:28 +0300 Subject: [PATCH 20/23] cache false --- .github/workflows/static_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 94258704c2..ccdd848bd4 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -95,7 +95,7 @@ jobs: with: environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env - cache-environment: true # this also caches the vcpkg builds + # cache-environment: true # this also caches the vcpkg builds init-shell: >- # bash is used in the vcpkg part cmd.exe bash From 2d246c2e1e089bde0871719928018cb5cfd9dd9a Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 14:51:21 +0300 Subject: [PATCH 21/23] test old --- .github/workflows/static_build.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index ccdd848bd4..0a753261d9 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -90,13 +90,19 @@ jobs: runs-on: windows-2019 steps: - uses: actions/checkout@v3 + - uses: mamba-org/provision-with-micromamba@main + if: true + with: + environment-file: ./libmamba/environment-static-dev.yml + environment-name: build_env - name: create build environment uses: mamba-org/setup-micromamba@v1 + if: false with: environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env # cache-environment: true # this also caches the vcpkg builds - init-shell: >- # bash is used in the vcpkg part + init-shell: >- cmd.exe bash powershell From b73796b423cff4a4aa2e5eb5ab265a2a8a772184 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 15:00:59 +0300 Subject: [PATCH 22/23] fix --- .github/workflows/static_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index 0a753261d9..b91bfd1846 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -93,7 +93,7 @@ jobs: - uses: mamba-org/provision-with-micromamba@main if: true with: - environment-file: ./libmamba/environment-static-dev.yml + environment-file: ./libmamba/environment-static-dev-win.yml environment-name: build_env - name: create build environment uses: mamba-org/setup-micromamba@v1 From aed21cec5dc6b1628fe1bc129f83bd8baab39893 Mon Sep 17 00:00:00 2001 From: Pavel Zwerschke Date: Sun, 30 Apr 2023 15:04:40 +0300 Subject: [PATCH 23/23] remove tmate --- .github/workflows/static_build.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/static_build.yml b/.github/workflows/static_build.yml index b91bfd1846..1e696e0b8d 100644 --- a/.github/workflows/static_build.yml +++ b/.github/workflows/static_build.yml @@ -128,9 +128,6 @@ jobs: text = text.replace("https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz", "https://repo.msys2.org/msys/x86_64/libtool-2.4.7-3-x86_64.pkg.tar.zst") f.write_text(text) - - run: | - bash.exe -c "echo hallo" - shell: cmd /C CALL {0} - name: build static windows dependencies with vcpkg shell: cmd /C CALL {0} run: | @@ -156,7 +153,8 @@ jobs: set CMAKE_PREFIX_PATH=%VCPKG_ROOT%\installed\x64-windows-static\;%CMAKE_PREFIX_PATH% if %errorlevel% neq 0 exit /b %errorlevel% - uses: mxschmitt/action-tmate@v3 - if: failure() + if: false + # if: failure() - uses: hendrikmuhs/ccache-action@main with: variant: sccache