From 52b38421c44c54fbd7fc9ca3a62d64db5183ca9e Mon Sep 17 00:00:00 2001 From: torzdf <36920800+torzdf@users.noreply.github.com> Date: Wed, 10 Jul 2024 23:58:22 +0100 Subject: [PATCH] setup.py: de-prioritize defaults on multi-channel conda installs --- setup.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/setup.py b/setup.py index 1b1fde6e6d..43475e05ad 100755 --- a/setup.py +++ b/setup.py @@ -1159,6 +1159,9 @@ def _from_conda(self, success = True condaexe = ["conda", "install", "-y"] if channels is not None: + if len(channels) > 1 and "defaults" in channels: + logger.debug("Setting default channel to lowest priority") + channels = [c for c in channels if c != "defaults"] + ["defaults"] for channel in channels: condaexe.extend(["-c", channel]) condaexe.append("--override-channels")