BCDA-APS / bluesky_training

Bluesky training, including instrument package
https://bcda-aps.github.io/bluesky_training/
Other
11 stars 0 forks source link

BUG libmamba solver not recognized #195

Closed prjemian closed 1 year ago

prjemian commented 1 year ago

After conda/conda-libmamba-solver#193, this error happens:

(bluesky_2023_2) prjemian@zap:~$ conda install -c conda-forge SOME_PACKAGE

CondaValueError: You have chosen a non-default solver backend (libmamba) but it was not recognized. Choose one of: classic

Very similar to https://github.com/conda/conda/issues/12868

prjemian commented 1 year ago

See this guide: https://conda.github.io/conda-libmamba-solver/getting-started/

prjemian commented 1 year ago

Check which channels provide which packages:

prjemian commented 1 year ago

The problem seems to occur when the mamba package is installed.

prjemian commented 1 year ago

Locally, with this new script, installation of additional proceeds as expected, without the reported exception.

prjemian commented 1 year ago

re-arrangement of the steps:

bash ${INSTALLER} -b -p "${INSTALL_DIR}"

# install libmamba, mamba, & micromamba
source "${INSTALL_DIR}/bin/activate"
conda update -y -n base conda
conda install -y -n base conda-libmamba-solver
# conda install -y -n base -c conda-forge mamba --solver=libmamba
conda install -y -n base -c conda-forge micromamba --solver=libmamba

# set some defaults (can override in local settings)
CONFIG_FILE="${INSTALL_DIR}/condarc"
echo "channels:" > "${CONFIG_FILE}"
echo "  - defaults" >> "${CONFIG_FILE}"
echo "  - conda-forge" >> "${CONFIG_FILE}"
echo "  - apsu" >> "${CONFIG_FILE}"
echo "  - aps-anl-tag" >> "${CONFIG_FILE}"
echo "channel_priority: flexible" >> "${CONFIG_FILE}"
echo "solver: libmamba" >> "${CONFIG_FILE}"