From 1e8cbd85c7c69801030998c73ef08fff40ca7d69 Mon Sep 17 00:00:00 2001 From: Timothy Willard <9395586+TimothyWillard@users.noreply.github.com> Date: Thu, 7 Nov 2024 09:55:37 -0500 Subject: [PATCH] Deactivate current env before activating new one This is to address a bug where a currently active env would cause the hpc init script to load the flepimop env not cleanly. Simplest solution is to always deactivate before activating. Redundant in the case that the flepimop env is already active, but easier than trying to determine the current env. No downside if no env is active. --- batch/hpc_init.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/batch/hpc_init.sh b/batch/hpc_init.sh index 71091f580..c90134a60 100644 --- a/batch/hpc_init.sh +++ b/batch/hpc_init.sh @@ -52,6 +52,7 @@ if [ -z "${FLEPI_CONDA}" ]; then fi echo "Using '$FLEPI_CONDA' for \$FLEPI_CONDA." fi +conda deactivate conda activate $FLEPI_CONDA # Check the conda environment is valid