diff --git a/wetb/prepost/simchunks.py b/wetb/prepost/simchunks.py
index 73a9ae115966a4470b1dca7d41fc76a89f8437e3..899e62948d8ff5bc05a50130144adf72d1a76fdb 100644
--- a/wetb/prepost/simchunks.py
+++ b/wetb/prepost/simchunks.py
@@ -220,14 +220,15 @@ def create_chunks_htc_pbs(cases, sort_by_values=['[Windspeed]'], ppn=20, i0=0,
             pbs += '%s %s\n' % rpl
             # sometimes activating an environment fails due to a FileExistsError
             # is this because it is activated at the same time on another node?
-            # check twice if the environment got activated for real
+            # check twice if the environment got activated for real,
+            # but only do so for /home/python/miniconda
             pbs += 'echo "CHECK 2x IF %s IS ACTIVE, IF NOT TRY AGAIN"\n' % pyenv
             pbs += 'CMD=\"from distutils.sysconfig import get_python_lib;'
-            pbs += 'print (get_python_lib().find(\'%s\'))"\n' % pyenv
+            pbs += 'print (get_python_lib().find(\'/usr/lib/python\'))"\n'
             pbs += 'ACTIVATED=`python -c "$CMD"`\n'
-            pbs += 'if [ $ACTIVATED -eq -1 ]; then %s %s;fi\n' % rpl
+            pbs += 'if [ $ACTIVATED -eq 0 ]; then %s %s;fi\n' % rpl
             pbs += 'ACTIVATED=`python -c "$CMD"`\n'
-            pbs += 'if [ $ACTIVATED -eq -1 ]; then %s %s;fi\n' % rpl
+            pbs += 'if [ $ACTIVATED -eq 0 ]; then %s %s;fi\n' % rpl
 
         # =====================================================================
         # create all necessary directories at CPU_NR dirs
diff --git a/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-gorm/remote_chnk_00000.p b/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-gorm/remote_chnk_00000.p
index 2e74bfeb2dcb2f0f7e543d3a85c25533d67f8b7e..4f403f2245343dc1c4634b4b9bec208b39c06879 100644
--- a/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-gorm/remote_chnk_00000.p
+++ b/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-gorm/remote_chnk_00000.p
@@ -16,11 +16,11 @@ echo "----------------------------------------------------------------------"
 echo "activate python environment wetb_py3"
 source /home/python/miniconda3/bin/activate wetb_py3
 echo "CHECK 2x IF wetb_py3 IS ACTIVE, IF NOT TRY AGAIN"
-CMD="from distutils.sysconfig import get_python_lib;print (get_python_lib().find('wetb_py3'))"
+CMD="from distutils.sysconfig import get_python_lib;print (get_python_lib().find('/usr/lib/python'))"
 ACTIVATED=`python -c "$CMD"`
-if [ $ACTIVATED -eq -1 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
+if [ $ACTIVATED -eq 0 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
 ACTIVATED=`python -c "$CMD"`
-if [ $ACTIVATED -eq -1 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
+if [ $ACTIVATED -eq 0 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
 
 echo "----------------------------------------------------------------------"
 cd /scratch/$USER/$PBS_JOBID/
diff --git a/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-jess/remote_chnk_00000.p b/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-jess/remote_chnk_00000.p
index fa2fb7783f7c89914a0095e3b41ac39b3c4d3092..baf98fa84dd6208a8d369cc69ec3adc01d893e27 100644
--- a/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-jess/remote_chnk_00000.p
+++ b/wetb/prepost/tests/data/demo_dlc/ref/zip-chunks-jess/remote_chnk_00000.p
@@ -16,11 +16,11 @@ echo "----------------------------------------------------------------------"
 echo "activate python environment wetb_py3"
 source /home/python/miniconda3/bin/activate wetb_py3
 echo "CHECK 2x IF wetb_py3 IS ACTIVE, IF NOT TRY AGAIN"
-CMD="from distutils.sysconfig import get_python_lib;print (get_python_lib().find('wetb_py3'))"
+CMD="from distutils.sysconfig import get_python_lib;print (get_python_lib().find('/usr/lib/python'))"
 ACTIVATED=`python -c "$CMD"`
-if [ $ACTIVATED -eq -1 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
+if [ $ACTIVATED -eq 0 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
 ACTIVATED=`python -c "$CMD"`
-if [ $ACTIVATED -eq -1 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
+if [ $ACTIVATED -eq 0 ]; then source /home/python/miniconda3/bin/activate wetb_py3;fi
 
 echo "----------------------------------------------------------------------"
 cd /scratch/$USER/$PBS_JOBID/