From 4866d09b2c03efe67470db7c26fcd8191e6ce840 Mon Sep 17 00:00:00 2001 From: Patrick Avery Date: Fri, 13 Oct 2023 13:58:15 -0500 Subject: [PATCH 1/2] Use the libmamba solver for packaging This will potentially run significantly faster, as also demonstrated in HEXRD/hexrd#562. Signed-off-by: Patrick Avery --- .github/workflows/package.yml | 4 ++++ packaging/environment.yml | 1 + 2 files changed, 5 insertions(+) diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 15636fba1..f82b70509 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -76,6 +76,10 @@ jobs: run: | conda activate hexrdgui-package mkdir output + + # Use libmamba as the solver for all future conda commands + export CONDA_SOLVER=libmamba + HEXRD_PACKAGE_CHANNEL=${HEXRD_PACKAGE_CHANNEL} HEXRDGUI_OUTPUT_FOLDER=output/ cpack # This is need to ensure ~/.profile or ~/.bashrc are used so the activate # command works. diff --git a/packaging/environment.yml b/packaging/environment.yml index 2b4ee5c8d..fc80c2aac 100644 --- a/packaging/environment.yml +++ b/packaging/environment.yml @@ -10,3 +10,4 @@ dependencies: - conda-build - conda-pack - click + - conda-libmamba-solver From 08056ed49e64e07d35d388dd6427f136f72d6f14 Mon Sep 17 00:00:00 2001 From: Patrick Avery Date: Fri, 13 Oct 2023 15:27:54 -0500 Subject: [PATCH 2/2] Try a couple more libmamba instructions Signed-off-by: Patrick Avery --- packaging/package.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packaging/package.py b/packaging/package.py index 80934fe98..1a87c499c 100644 --- a/packaging/package.py +++ b/packaging/package.py @@ -128,6 +128,7 @@ def build_conda_pack(base_path, tmp, hexrd_package_channel, hexrdgui_output_fold config.variant['hexrd_version'] = hexrd_version config.CONDA_PY = '38' + config.CONDA_SOLVER = 'libmamba' logger.info('Building hexrdgui conda package.') CondaBuild.build(recipe_path, config=config) @@ -155,6 +156,7 @@ def build_conda_pack(base_path, tmp, hexrd_package_channel, hexrdgui_output_fold params = [ Conda.Commands.INSTALL, '--prefix', env_prefix, + '--solver', 'libmamba', '--override-channels', '--channel', hexrdgui_output_folder_uri, '--channel', hexrd_package_channel,