Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add mamba and conda-libmamba-solver to Miniforge (Mambaforge is now identical) #277

Merged
merged 7 commits into from
Aug 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Miniforge3/construct.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{% set version = os.environ.get("MINIFORGE_VERSION", "23.3.0-0") %}
{% set name = os.environ.get("MINIFORGE_NAME", "Miniforge3") %}
{% set version = os.environ.get("MINIFORGE_VERSION", "23.3.1-0") %}
{% set conda_libmamba_solver_version = "23.3.0"%}
{% set mamba_version = "1.4.2"%}

name: {{ name }}
version: {{ version }}
Expand Down Expand Up @@ -28,11 +30,9 @@ specs:
{% else %}
- python 3.10.*
{% endif %}

{% if name.startswith("Mambaforge") %}
- mamba 1.4.2
{% endif %}
- conda {{ version.split("-")[0] }}
- conda-libmamba-solver {{ conda_libmamba_solver_version }}
- mamba {{ mamba_version }}

Comment on lines 33 to +35
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah nvm looks like the version is tied to how Conda & friends are versioned. Submitted PR ( #480 ) to address this

- pip
- miniforge_console_shortcut 1.* # [win]
2 changes: 1 addition & 1 deletion scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ echo "***** Install constructor *****"
mamba install --yes \
--channel conda-forge --override-channels \
jinja2 curl libarchive \
"constructor>=3.4.4"
"constructor>=3.4.5"

if [[ "$(uname)" == "Darwin" ]]; then
mamba install --yes \
Expand Down
43 changes: 17 additions & 26 deletions scripts/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ else
fi
INSTALLER_PATH=$(find build/ -name "*forge*.${EXT}" | head -n 1)
INSTALLER_NAME=$(basename "${INSTALLER_PATH}" | cut -d "-" -f 1)
INSTALLER_EXE=$(basename "${INSTALLER_PATH}")

echo "***** Run the installer *****"
chmod +x "${INSTALLER_PATH}"
Expand All @@ -46,18 +45,13 @@ if [[ "$(uname)" == MINGW* ]]; then
conda.exe install r-base --yes --quiet
conda.exe list

# hmaarrfk -- 2023/02
# For some reason the Mambaforge-Linux-ppc64le works fine in under 15 mins on a branch
# but then fails to build within the 6 hour time limit on the release CI.
if [[ "${INSTALLER_NAME}" == "Mambaforge" ]] && [[ "${INSTALLER_EXE}" != "Mambaforge-Linux-ppc64le.sh" ]]; then
echo "***** Mambaforge detected. Checking for boa compatibility *****"
mamba_version_start=$(mamba --version | grep mamba | cut -d ' ' -f 2)
mamba.exe install boa --yes
mamba_version_end=$(mamba --version | grep mamba | cut -d ' ' -f 2)
if [[ "${mamba_version_start}" != "${mamba_version_end}" ]]; then
echo "mamba version changed from ${mamba_version_start} to ${mamba_version_end}"
exit 1
fi
echo "***** Checking for boa compatibility *****"
mamba_version_start=$(mamba --version | grep mamba | cut -d ' ' -f 2)
mamba.exe install boa --yes
mamba_version_end=$(mamba --version | grep mamba | cut -d ' ' -f 2)
if [[ "${mamba_version_start}" != "${mamba_version_end}" ]]; then
echo "mamba version changed from ${mamba_version_start} to ${mamba_version_end}"
exit 1
fi
else
# Test one of our installers in batch mode
Expand Down Expand Up @@ -86,19 +80,16 @@ EOF
conda info
conda list

if [[ "${INSTALLER_NAME}" == "Mambaforge" ]]; then
echo "***** Mambaforge detected. Checking for boa compatibility *****"
implementation=$(python -c "import platform; print(platform.python_implementation().lower())")
major_minor_version=$(python -c 'import sys; print(f"{sys.version_info[0]}.{sys.version_info[1]}")')
mamba_version_start=$(mamba --version | grep mamba | cut -d ' ' -f 2)
mamba info
mamba install "mamba=${mamba_version_start}" "python=${major_minor_version}.*=*_${implementation}" boa --yes
mamba_version_end=$(mamba --version | grep mamba | cut -d ' ' -f 2)
if [[ "${mamba_version_start}" != "${mamba_version_end}" ]]; then
echo "mamba version changed from ${mamba_version_start} to ${mamba_version_end}"
exit 1
fi

echo "***** Checking for boa compatibility *****"
implementation=$(python -c "import platform; print(platform.python_implementation().lower())")
major_minor_version=$(python -c 'import sys; print(f"{sys.version_info[0]}.{sys.version_info[1]}")')
mamba_version_start=$(mamba --version | grep mamba | cut -d ' ' -f 2)
mamba info
mamba install "mamba=${mamba_version_start}" "python=${major_minor_version}.*=*_${implementation}" boa --yes
mamba_version_end=$(mamba --version | grep mamba | cut -d ' ' -f 2)
if [[ "${mamba_version_start}" != "${mamba_version_end}" ]]; then
echo "mamba version changed from ${mamba_version_start} to ${mamba_version_end}"
exit 1
fi
fi

Expand Down
Loading