Steps to reproduce
I have a shell script wrapper in my ~/bin/ called cl-repl which starts up the sbcl common lisp interpreter, with some options I like by default wrapped in rlwrap. For reasons I don't understand, when I have this in my $PATH and run spack with any options, spack tries to run it. This causes it to hang, because it's a REPL, and then when I kill it mess up my terminal entirely because of rlwrap.
and then on another terminal
$ ps xjf
16612 16643 16612 16612 ? -1 S 55052 0:00 sshd: uccaoke@pts/31
16643 16645 16645 16645 pts/31 17638 Ss 55052 0:00 \_ -bash
16645 17638 17638 16645 pts/31 17638 S+ 55052 0:00 \_ screen
17638 17639 17639 17639 ? -1 Ss 55052 0:00 \_ SCREEN
17639 17640 17640 17640 pts/32 29663 Ss 55052 0:00 \_ /bin/bash
17640 29663 29663 17640 pts/32 29663 Sl+ 55052 0:00 | \_ /opt/rh/rh-python38/root/usr/bin/python3 /home/uccaoke/Source/spack/bin/spack compiler find
29663 29870 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29870 30630 29663 17640 pts/32 29663 S+ 55052 0:00 | | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30630 30642 30642 30642 pts/51 30642 Ssl+ 55052 0:00 | | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
29663 29892 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29892 30632 29663 17640 pts/32 29663 S+ 55052 0:00 | | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30632 30641 30641 30641 pts/47 30641 Ssl+ 55052 0:00 | | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
29663 29895 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29895 30631 29663 17640 pts/32 29663 S+ 55052 0:00 | | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30631 30638 30638 30638 pts/46 30638 Ssl+ 55052 0:00 | | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
29663 29916 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29916 30636 29663 17640 pts/32 29663 S+ 55052 0:00 | | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30636 30643 30643 30643 pts/52 30643 Ssl+ 55052 0:00 | | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
29663 29922 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29922 30635 29663 17640 pts/32 29663 S+ 55052 0:00 | | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30635 30639 30639 30639 pts/45 30639 Ssl+ 55052 0:00 | | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
29663 29941 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ /bin/bash -l /home/uccaoke/bin/cl-repl
29941 30637 29663 17640 pts/32 29663 S+ 55052 0:00 | \_ rlwrap sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf
30637 30640 30640 30640 pts/48 30640 Ssl+ 55052 0:00 | \_ sbcl --noinform --eval (setf *read-default-float-format* 'double-float) --eval (require 'sb-aclrepl) --eval (setf sb
17639 31956 31956 31956 pts/53 32512 Ss 55052 0:00 \_ /bin/bash
31956 32512 32512 31956 pts/53 32512 R+ 55052 0:00 \_ ps xjf
Error message
There is no error message, it just hangs forever waiting for input.
Running with --debug:
$ spack --debug compiler find
==> [2023-08-25-10:18:40.480534] Imported compiler from built-in commands
==> [2023-08-25-10:18:40.482537] Imported compiler from built-in commands
==> [2023-08-25-10:18:40.710087] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.710443] '/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.710827] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.711382] '/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.711637] '/opt/rh/devtoolset-11/root/usr/bin/cc' '--version'
==> [2023-08-25-10:18:40.712313] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.711101] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.717078] '/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.717546] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.726690] '/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.728438] '/shared/ucl/apps/gcc/4.9.2/bin/gcc' '--version'
==> [2023-08-25-10:18:40.728986] '/usr/bin/gcc' '--version'
==> [2023-08-25-10:18:40.716624] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.733329] '/opt/rh/devtoolset-11/root/usr/bin/g++' '--version'
==> [2023-08-25-10:18:40.721678] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.737693] '/usr/bin/g++' '--version'
==> [2023-08-25-10:18:40.738859] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.709797] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '--version'
==> [2023-08-25-10:18:40.739369] '/usr/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.747258] '/shared/ucl/apps/gcc/4.9.2/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.727962] '/opt/rh/devtoolset-11/root/usr/bin/gcc' '--version'
==> [2023-08-25-10:18:40.749454] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.755859] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.757735] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.757346] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.737020] '/shared/ucl/apps/gcc/4.9.2/bin/g++' '--version'
==> [2023-08-25-10:18:40.738383] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.745784] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.711960] '/usr/bin/cc' '--version'
==> [2023-08-25-10:18:40.748039] '/usr/bin/gfortran' '-dumpversion'
==> [2023-08-25-10:18:40.787335] '/usr/bin/g++' '-dumpversion'
==> [2023-08-25-10:18:40.792806] '/opt/rh/devtoolset-11/root/usr/bin/gcc' '-dumpversion'
==> [2023-08-25-10:18:40.801614] '/usr/bin/gcc' '-dumpversion'
==> [2023-08-25-10:18:40.769014] '/shared/ucl/apps/gcc/4.9.2/bin/gcc' '-dumpversion'
==> [2023-08-25-10:18:40.748896] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.813419] '/shared/ucl/apps/gcc/4.9.2/bin/g++' '-dumpversion'
==> [2023-08-25-10:18:40.817682] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '-dumpfullversion'
==> [2023-08-25-10:18:40.845011] '/opt/rh/devtoolset-11/root/usr/bin/gcc' '-dumpfullversion'
==> [2023-08-25-10:18:40.788064] '/opt/rh/devtoolset-11/root/usr/bin/g++' '-dumpversion'
==> [2023-08-25-10:18:40.756969] '/home/uccaoke/bin/cl-repl'
==> [2023-08-25-10:18:40.869786] '/opt/rh/devtoolset-11/root/usr/bin/gfortran' '-dumpfullversion'
==> [2023-08-25-10:18:40.882827] '/opt/rh/devtoolset-11/root/usr/bin/g++' '-dumpfullversion'
I'm guessing from this it's doing some sort of wildcard search of things in $PATH and assuming it's a compiler?
$ spack debug report
* **Python:** 3.8.11
* **Platform:** linux-rhel7-skylake_avx512
* **Concretizer:** clingo
Information on your system
This happens reproducibly with a clean install of Spack on any system I test it on (multiple HPC systems at UCL, VMs etc).
General information
Steps to reproduce
I have a shell script wrapper in my
~/bin/calledcl-replwhich starts up the sbcl common lisp interpreter, with some options I like by default wrapped inrlwrap. For reasons I don't understand, when I have this in my$PATHand runspackwith any options,spacktries to run it. This causes it to hang, because it's a REPL, and then when I kill it mess up my terminal entirely because ofrlwrap.$ spack compiler findand then on another terminal
Error message
There is no error message, it just hangs forever waiting for input.
Running with
--debug:I'm guessing from this it's doing some sort of wildcard search of things in
$PATHand assuming it's a compiler?Information on your system
This happens reproducibly with a clean install of Spack on any system I test it on (multiple HPC systems at UCL, VMs etc).
General information
spack debug reportand reported the version of Spack/Python/Platform