5.5.0
- Init: update
cmdshell initialization script to correctly defineMODULESHOMEwhen installation pathname contains dot character. (fix issue #525 with contribution from V-clone) - Init: add completion for
mlcommand on Tcsh shell. (fix issue #416 with contribution from Laurent Besson) - Init: fix completion of
mod-to-sh's options on Bash and Tcsh shells. - Fix modulepath file search when libtclenvmodules is disabled and modulepath contains glob characters.
- Lib: correct libtclenvmodules to retrieve all user groups on Darwin systems when user is member of more than 16 groups.
- Script: output testsuite run progress on
mtdevelopment utility. - Resolve switched-on module prior testing stickiness preservation.
- Contrib: fix versions modulefiles generated when
--enable-versioninginstallation option is set. Use--not-reqoption onmodule unloadcommands to avoid declaring a conflict toward these modules to unload. (fix issue #531) - Add
hide-modulefileandhide-versionmodulerc commands to support modulerc files written for Lmod. - Update
autoinitsub-command to definemoguishell function or alias ifmogui-cmdcommand is found inPATH. - Add the
hide_auto_loadedconfiguration option to tag automatically loaded moduleshidden-loaded. These modules will not appear onlistsub-command output unless--alloption is set. Option is disabled by default and when set, it defines theMODULES_HIDE_AUTO_LOADEDenvironment variable. - Introduce the
--modulepathoption to thealways-load,depends-on,prereq,prereq-allandprereq-anymodulefile commands. When this option is set, required module should be located in a path listed in the specified list or in an enabled modulepath matching one path of the list. This information is recorded in loaded environment in__MODULES_LMPREREQPATHvariable. - Add
lsb-releasemodulefile command to get certain Linux Standard Base (LSB) information. It accepts to following sub-commands:id,codenameandrelease. - Add information logging capabilities controlled by two new configuration options:
loggerwhich defines the command to use to sent information to the log system andlogged_eventswhich controls the information sent to logs. loggerconfiguration option relies on theloggercommand by default. It can be changed at installation time with--with-loggerand--with-logger-optsoptions. Whenloggeris changed withconfigsub-command, it sets theMODULES_LOGGERenvironment variable.loggercan be declared as a locked configuration option inlocked_configs.logged_eventsconfiguration option is a list of event names separated by colon character. It is empty by default, thus nothing is logged by default. Allowed event names arerequested_cmd(log module commands directly executed by users),requested_eval(modulefile evaluations directly asked by users) andauto_eval(modulefile evaluations automatically triggered). Option value can be changed at installation time with--with-logged-eventsoption. Whenlogged_eventsis changed withconfigsub-command, it sets theMODULES_LOGGED_EVENTSenvironment variable.logged_eventscan be declared as a locked configuration option inlocked_configs.- Add
logchannel to theputsmodulefile command. String message passed toputs logis sent to theloggercommand. - Doc: update
log-module-commandcookbook recipe with integrated logging feature. - Install: update
configurescript to ignore all--with-*options if no value is associated to them. - Install: update
configurescript to set option to an empty string if specified with--without-*argument. Exception is made for--without-icasewhich sets option to thenevervalue. - Introduce
not:prefix for extra specifier and variant criteria on module search context. This prefix allows to negate search criteria onExtra match searchmechanism. - Adopt stricter naming rule for variant names. Only characters within the
A-Za-z0-9_-range are allowed. Also, a variant name cannot start with-(minus) character and the overall name cannot just be a number. - Allow
+and~characters to be part of module name or version specification as long as the string following them is not a valid variant name (e.g.,foo/1.2+8). (fix issue #527) - In case of an issue external to Modules, do not mention at the end of the error stack trace the web link to report this issue. (fix issue #546)
- When a modulefile performs a
module unloadcommand that fails due to dependent modules loaded, stop unload evaluation right after this failed command unless--forceoption is used. - Exclude sticky modules from the useless requirement unload mechanism as they cannot be unloaded.
- Tag automatically loaded module
auto-loadedprior evaluation to be able to query this state during modulefile evaluation withmodule-info tags. - Doc: describe in
module(1)man page how to initialize Modules in a Ruby script. (fix issue #535) - Add PowerShell Core (
pwsh) shell support. (fix issue #326 with contribution from Simon Lukas Märtens) - Lib: adapt Modules Tcl extension library to properly load on Tcl 9.
- Doc: describe how to upgrade Modules in
INSTALL. (fix issue #544) - Set exit code returned by
modulecmd.tclscript to1when a modulefile evaluation fails (modulefile does not exist, is buggy, etc). (fix issue #540) - Disable pager when running
modulecmd.tclscript for script language (python, perl, ruby, tcl, cmake, r and lisp). (fix issue #542) - Update error and warning messages when attempting to unload a module required by another. Distinguish if this module is a requirement of an already loaded or a currently loading module.
- Introduce
conflict_unloadconfiguration option that controls whether or not conflicting modules and their dependent should be unloaded when loading a module. All kind of conflicts are supported: conflicts defined by already loaded modules, conflict declared by loading module throughconflict,familyormodule unloadcommands.conflict_unloadalso handles the unload of a module that is loaded again but with different variant values or from a different modulepath.conflict_unloadis disabled by default as it changes behaviors of the automated module handling mode. But everyone is encouraged to enable this new option to benefit from an highly automated experience. This option can be changed at installation time with--enable-conflict-unload. Whenconflict_unloadis changed withconfigsub-command, it sets theMODULES_CONFLICT_UNLOADenvironment variable. Bothauto_handlingandconflict_unloadoptions should be enabled to activate Conflict Unload automated behavior. (fix issue #242) - When both
auto_handlingandconflict_unloadoptions are enabled, all loaded modules matching module specifications set onconflictormodule unloadcommands are unloaded. If both options are not enabled, only one matching loaded module per specification argument ofmodule unloadis unloaded. (fix issue #215) - When both
auto_handlingandconflict_unloadoptions are enabled,--forceoption set onloadsub-command is taken into account during the Conflict Unload mechanism. For instance, it continues this unload process even if one module unload fails. - Install: installation option
--enable-new-featuresis updated to include--enable-conflict-unload. - Fix detection of already loaded module with variant set. If trying to load same module with compatible variant set, a module is already loaded message is now returned instead of another variant is loaded.
- Correctly report module evaluation error in case during the same execution this module was already evaluated and failed silently during a Requirement Load mechanism.
- Split processing of Dependent Reload (DepRe) modules to treat the DepRe modules consequence of Useless Requirement Unload (UReqUn) modules separately, right before unloading the UReqUn modules. As a result, modules in conflict with UReqUn modules are unloaded right before UReqUn process and reloaded with the other DepRe modules.
- Handle UReqUn process in case of
switchsub-command after the switch load phase. Unload of these modules were previously occurring at the end of the switch unload phase. Unload of DepRe modules consequence of UReqUn modules is also moved after switch load phase. - Introduce the Useless Requirement Unload (UReqUn) process on
loadsub-command. It eliminates auto loaded modules that were requirements of Conflict Unload modules. In case ofswitchsub-command, UReqUn modules coming from the switch load phase are handled with UReqUn modules coming from switch unload phase. - Rework handling of DepRe modules that also are UReqUn modules to unload them during the DepRe unload phase instead of during UReqUn process. As a consequence these modules part of both DepRe and UReqUn lists are unloaded prior main module action and prior unload of the other UReqUn modules. The DepRe modules may be also qualified UReqUn even if they are not a dependency of a module unloaded in the current processing.
- Mix unload of Dependent Unload and Dependent Reload modules to ensure they are processed in their reverse loading order. As a result, if a module is part of DepUn process and some of its requirements are part of DepRe process, requirements are unloaded after their dependent modules.
- Skip reload of a Dependent Reload module if found not loadable (either its requirements are not loaded or a conflict is spotted with loaded environment). Reload is attempted only if module is tagged super-sticky or sticky and force mode is disabled. Skipped module is considered Dependent Unload module.
- Reload all Dependent Reload modules after the main load, unload or switch module evaluation rather after the sub module evaluation that triggered the Dependent Reload unload phase.
- Dependent Unload modules of Conflict Unload modules are merged into the Dependent Reload module list. An attempt to reload these dependent modules is tried only if their requirements are satisfied by loaded environment.
- When a loading module requires a Dependent Unload module, the unload of this module was forced when it was triggered by a Conflict Unload or a switched-off module. The unload of such Dependent Unload module is not forced anymore by default and an error is raised if a loading module requiring the Dependent Unload module is detected.
- When unloading Dependent Reload modules, do not force by default this unload unless asked with
--forceoption. As a result an error is obtained when trying to reload Dependent Reload modules that conflict with other loaded modules. This error may be by-passed with--forcecommand-line option. - Move stickiness check when unloading a module prior processing any automated module handling mechanism. (fix issue #536)
Caution
Variant names are now fully checked instead of just verifying their first character. Only characters within the A-Za-z0-9_- range are allowed. Variant name cannot start with - character and the overall name cannot just be a number.
Warning
Existing versions modulefiles generated by --enable-versioning installation option and installed for Modules 4.7 and upward should be manually fixed by adding the --not-req option to the module unload commands present in these modulefiles. Following command should fix these files: sed -i "s|module unload|module unload --not-req|" <version_modulefile>.