-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No non-zero exit code when running show
over a non-existent module
#743
Comments
Thanks very much for reporting this issue. I have uploaded branch IS743-show to github that fixes this for me. This change comes down to changing the warning to an error when show cannot find a module. @xdelaruelle : Please test out this branch if you get the change and report back Thanks! |
Many thanks Robert. I have test the new branch and it gives me the expected result with the I have also run the Input from @boegel is important to determine if this change does not break all existing installation of EasyBuild using Lmod if people decide to update Lmod to the latest version. |
Closing this issue. If easybuild has an issue then please feel free to re-open. Thanks again for the bug-report. |
Sorry for not answering here yet... While I support this change (a non-zero exit code for While the problem is already being fixed via easybuilders/easybuild-framework#4739 (thanks @xdelaruelle!), this essentially makes all current EasyBuild releases incompatible with Lmod 8.7.56+, which seems quite harsh... Is there something we can do to prevent this? EasyBuild has set @rtmclay Giving the impact of this breaking change, can we re-open this issue to see if we can come up with something to avoid the problems we see with Lmod 8.7.56 in EasyBuild? |
…dWarning except when $LMOD_QUIET is set
I have uploaded to branch IS743-show the changes you requested. Namely @boegel Please branch to see if it works for you. |
@rtmclay Works like a charm!
I've also verified that it fixes the incompatibility issue with EasyBuild So will this become Lmod 8.7.57? |
Hello Lmod Team,
To be more in line with Lmod, I have made
modulecmd.tcl
command return a non-zero exit code when a module evaluation fails. This is a regular behavior for any kind of command when something goes wrong, like for instance in our field when trying to evaluate a module that does not exist.I am working to adapt EasyBuild to make it fit this behavior change in Environment Modules v5.5 (easybuilders/easybuild-framework#4739) and I found something that may be of interest for you.
Describe the issue
EasyBuild is internally running the
show
sub-command to determine if a module exist or not.When trying to load a non-existent module, the
lmod
script sets a non-zero exit code.But when running the
show
sub-command, thelmod
script sets a zero exit code whether the module exist or not.To Reproduce
Expected behavior
As
show
sub-command makes a module evaluation likeload
sub-command, it may be interesting to produce an error (and makelmod
script sets a non-zero exit code) when trying to evaluate a non-exiting module.Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: