Hi Gilles,
I can reproduce this behavior ... when running outside of a slurm allocation.
I just tried from slurm (sbatch run.sh) and I get the exact same error.
What does $ env | grep ^SLURM_ reports?
Empty; no environment variables have been defined. Thanks, Andrej