Describe the bug
Path ordering is different before and after a module reload, which was unexpected.
To Reproduce
Steps to reproduce the behavior:
$ echo $MYPATH
$ module load FOOFOO
Loading FOOFOO
Loading requirement: BARBAR
$ echo $MYPATH
/home/BAR:/home/FOO
$ module reload
$ echo $MYPATH
/home/FOO:/home/BAR
Location and content of any modulerc or modulefile involved:
$ cat FOOFOO
#%Module1.0 # -*- tcl -*-
prepend-path MYPATH /home/FOO
module load BARBAR
$ cat BARBAR
#%Module1.0 # -*- tcl -*-
prepend-path MYPATH /home/BAR
Expected behavior
$MYPATH path variable consistent before and after reload
Error and debugging information
$ module --debug <command1> <arguments>
$ module --debug <command2> <arguments>
...
Modules version and configuration
$ module --version
Modules Release 5.0.0 (2021-09-12)
# The same behavior exists in 4.3.x, 4.5.x and 4.6.x as well.
Additional context
It is worth noting that if all prepend-paths above are changed to append-path then the same ordering issue occurs.
Describe the bug
Path ordering is different before and after a
module reload, which was unexpected.To Reproduce
Steps to reproduce the behavior:
Location and content of any modulerc or modulefile involved:
Expected behavior
$MYPATHpath variable consistent before and after reloadError and debugging information
Modules version and configuration
Additional context
It is worth noting that if all
prepend-paths above are changed toappend-paththen the same ordering issue occurs.