use force-reinstall

not deprecated --force
This commit is contained in:
Min RK
2023-06-09 14:16:27 +02:00
parent 4cc55df2a4
commit 29b354b42b

View File

@@ -113,7 +113,9 @@ def ensure_conda_packages(prefix, packages, force=False):
cmd = [conda_executable, "install", "--yes"] cmd = [conda_executable, "install", "--yes"]
if force: if force:
cmd += ["--force"] # use force-reinstall, e.g. for conda/mamba to ensure everything is okay
# avoids problems with RemoveError upgrading conda from old versions
cmd += ["--force-reinstall"]
abspath = os.path.abspath(prefix) abspath = os.path.abspath(prefix)