Debian Codegraph @

doc/source/NEWS.rst

raw
1 .. _NEWS:
2
3 Release notes
4 =============
5
6 This file describes changes in recent versions of Modules. It primarily
7 documents those changes that are of interest to users and admins.
8
9 .. _5.6 release notes:
10
11 Modules 5.6.2 (2026-09-07)
12 --------------------------
13
14 * Init: fix command injection in Bash completion when module names contain
15 shell meta-characters. Completion candidates were passed to ``compgen -W``
16 which evaluates command substitution syntax. (fix `CVE-2026-85013`_ found
17 by AISLE in partnership with Red Hat)
18
19 .. _CVE-2026-85013: https://github.com/envmodules/modules/security/advisories/GHSA-8hrw-p88g-qhmg
20
21
22 Modules 5.6.1 (2025-11-25)
23 --------------------------
24
25 * Script: improve :command:`mrel` to better support Koji states and not rely
26 on sudo privileges to test a new release.
27 * Script: adapt utilities to only use :command:`curl` rather also requiring
28 :command:`wget`.
29 * Doc: :ref:`CHARTER` has been approved on September 4, 2025.
30 * Doc: add :ref:`EESSI` design notes.
31 * Doc: update :ref:`modulefile(5)` man page to describe the :mfcmd:`report`
32 modulefile command, which is supported since version 4.0.
33 * Doc: use `Furo`_ Sphinx theme for the documentation published on Read The
34 Docs.
35 * Doc: describe how to call modulefile command from a hook procedure in
36 :ref:`module(1)` man page. (fix issue #590)
37 * Doc: add warning in :ref:`INSTALL-win` to mention :command:`ml` command name
38 conflict with *MSVC x86 toolchain* ``ml.exe``. (fix issue #589)
39 * Doc: add :ref:`maintainer-guide`.
40 * Doc: website is now located at https://envmodules.io.
41 * Doc: precise that no automatic path resolution is performed on
42 :mfcmd:`prepend-path`, :mfcmd:`append-path` or :mfcmd:`remove-path`
43 modulefile commands. (fix issue #597)
44 * Doc: add way to build latexpdf documentation.
45 * Ensure that a module having the same name than a loaded module from
46 another modulepath does not inherit its tags. (fix issue #599)
47 * Drop tags stored in memory that applies to a module when unloading it. It
48 ensures that tags applied to the module when reloaded from a different
49 modulepath are not inherited.
50 * Always apply *abort on error* behavior in case a Dependent Reload sticky
51 (and :option:`--force` is not set) or super-sticky module fails to reload.
52 (fix issue #601)
53 * When loading a module, check already loaded modules and their aliases
54 exactly matching specification before looking at available modules and their
55 aliases. (fix issue #602)
56
57 .. _Furo: https://github.com/pradyunsg/furo
58
59
60 Modules 5.6.0 (2025-07-31)
61 --------------------------
62
63 * Rename :file:`contrib` directory as :file:`share` in sources to use clearer
64 name for architecture and configuration independent files.
65 * Set a `Security policy`_ for the project.
66 * Add red, white and black SVG logo files of Modules project.
67 * Doc: improve Links, Community sections in documentation index and README
68 * Doc: improve Authors and Acknowledgments sections in README
69 * Doc: add :ref:`create-new-release` guide
70 * Update repository URL to https://github.com/envmodules/modules.
71 * Install: update :file:`configure` script to allow running it from a current
72 working directory different than where this file is stored. (fix issue #558)
73 * Doc: create *Developer HowTos* section on documentation website to group
74 development how-to guides.
75 * Doc: add :ref:`acknowledgments` page in the documentation.
76 * Doc: describe :ref:`GOVERNANCE`.
77 * Doc: add :ref:`CHARTER`.
78 * Escape square brackets (``[]``) used in values within produced shell code as
79 these characters may have special meaning on some shells (like *csh*). (fix
80 issue #565)
81 * Doc: advertise the `Modules chat room`_ (``#modules:matrix.org``) to discuss
82 with the community.
83 * Doc: describe the :ref:`developer-certificate-of-origin` process now applied
84 on contributions.
85 * Doc: add :ref:`add-new-maintainer` guide
86 * Fix interpreter variable reset between multiple modulefile or modulerc
87 evaluations when variable initial value is an invalid list. (fix issue #570)
88 * Fix :mfcmd:`source-sh` and :subcmd:`sh-to-mod` shell translation when used
89 with new *fish* shell version (4.0).
90 * Doc: add :ref:`mode-select` design notes.
91 * Introduce ``use`` extra specifier to search for :envvar:`MODULEPATH` changes
92 performed with :mfcmd:`module use<module>`, :mfcmd:`append-path` or
93 :mfcmd:`prepend-path` modulefile commands on :subcmd:`avail`,
94 :subcmd:`whatis` and :subcmd:`paths` sub-commands.
95 * Add :option:`--dumpname` option to report name of current Environment
96 Modules implementation. Here it returns ``Modules``. This option is also
97 available on Lmod starting version 8.7.50.
98 * Add the :mfcmd:`depends-on-any` modulefile command, alias over the
99 :mfcmd:`prereq` command for compatibility with Lmod Tcl modulefiles.
100 * Add ``depends-on-any`` extra specifier to query modulefile requirement
101 definitions. The extra specifier aliases ``prereq``, ``prereq-any`` or
102 ``require`` may also be used to query this modulefile command.
103 * Introduce the :subcmd:`spider` sub-command that lists available modules
104 found in enabled modulepaths and recursively found in modulepaths enabled by
105 available modules. After a first step aimed at collecting all modulepaths,
106 :subcmd:`spider` proceeds and reports like :subcmd:`avail` sub-command. The
107 same set of options are supported.
108 * Introduce the :mconfig:`spider_output` and :mconfig:`spider_terse_output`
109 configuration options to define the content to report in addition to the
110 available module names respectively for :subcmd:`spider` sub-command regular
111 and terse output modes. Excepted value for these configuration options is a
112 colon separated list of elements to report. Default value is
113 ``modulepath:alias:dirwsym:sym:tag:variantifspec:key`` for
114 :mconfig:`spider_output` and
115 ``modulepath:alias:dirwsym:sym:tag:variantifspec`` for
116 :mconfig:`spider_terse_output`. These values can be changed at installation
117 time respectively with the :instopt:`--with-spider-output` and
118 :instopt:`--with-spider-terse-output` options. These values can then be
119 superseded by using the :subcmd:`config` sub-command which sets the
120 :envvar:`MODULES_SPIDER_OUTPUT` and :envvar:`MODULES_SPIDER_TERSE_OUTPUT`
121 environment variables.
122 * Introduce the ability to control whether :subcmd:`spider` command search
123 results should recursively include or not modulefiles from directories
124 matching search query by use of the :option:`--indepth` and
125 :option:`--no-indepth` command-line switches or :mconfig:`spider_indepth`
126 configuration option (that sets :envvar:`MODULES_SPIDER_INDEPTH` environment
127 variable through :subcmd:`config` command). Default value (enabled) may also
128 be changed at installation time with
129 :instopt:`--disable-spider-indepth<--enable-spider-indepth>` option.
130 * Doc: add :ref:`spider-sub-command` design notes.
131 * The :subcmd:`lint` sub-command now also lint any readable modulecache files
132 when no modulefile specification is passed as argument or if
133 :file:`.modulecache` file location is specifically passed as argument.
134 * Add the ``hidden`` element in the allowed value list of the
135 :mconfig:`avail_output`, :mconfig:`avail_terse_output`,
136 :mconfig:`list_output`, :mconfig:`list_terse_output`,
137 :mconfig:`spider_output` and :mconfig:`spider_terse_output` configuration
138 options. When set, it is equivalent to use :option:`--all` option: hidden
139 modules are shown.
140 * Produce a single output for multi pattern :subcmd:`avail` search rather than
141 a separate output for each submitted pattern.
142 * Produce a single output for multi pattern :subcmd:`whatis` search rather
143 than a separate output for each submitted pattern.
144 * Doc: clarify that character used in version specification like *,* and *:*
145 cannot be used as variant shortcut.
146 * Introduce :envvar:`__MODULES_LMUSE` environment variable to keep track of
147 the loaded modules that enable modulepaths.
148 * Apply modulepath label defined with :mfcmd:`modulepath-label` also on output
149 of :subcmd:`whatis` and :subcmd:`search` sub-commands.
150 * Report *via* information for each module entry on JSON output of
151 :subcmd:`avail` and :subcmd:`spider` sub-commands. *Via* information is the
152 name of the loaded or interpreted module that enables the modulepath in
153 which reported modules are stored.
154 * Add the ``via`` element in the allowed value list of the
155 :mconfig:`avail_output` and :mconfig:`spider_output` configuration options.
156 When set, if a modulepath is enabled by a module, this module name is
157 reported next to the modulepath name. ``via`` element is not available for
158 terse output mode. ``via`` is set by default in :mconfig:`spider_output`
159 configuration option.
160 * Add ``modules_release`` internal state. It will help to know the current
161 version of Modules within :file:`siteconfig.tcl` script.
162 * Introduce :mfcmd:`module-help` modulefile command which defines help text to
163 print when modulefile is evaluated in ``help`` mode.
164 * Update :mfcmd:`add-property` modulefile command to use its *value* argument
165 to define tag on currently loading module.
166 * Doc: add :ref:`module-warn` design notes.
167 * Add :mfcmd:`module-warn` modulerc and modulefile command which prints a
168 warning message when designated modulefile is evaluated. This command
169 accepts options to emit the warning only for specific users, groups or
170 times.
171 * Introduce the ``warning`` informational :ref:`module tag<Module tags>` on
172 modulefiles targeted by :mfcmd:`module-warn` command. Update default
173 :mconfig:`tag_abbrev` configuration option to add an abbreviation for the
174 new tag (``W``) and default light and dark color palettes.
175 * Change light and dark color palettes for ``nearly-forbidden`` tag (red text
176 with yellow background), to make it look closer to ``forbidden`` tag (red
177 background) and distinguish it from new ``warning`` tag (black text and
178 yellow background).
179 * No raise of *nearly-forbidden* warning when affected modulefile is evaluated
180 in ``refresh`` mode.
181 * Issue the *nearly-forbidden* warning at the end of the affected modulefile
182 evaluation, ensuring it is always reported at the same stage regardless of
183 where it is defined.
184 * Change underlying shell code to set environment variable on *sh*, *bash*,
185 *ksh*, *zsh* and *fish* shells: enclose value within single quotes rather
186 escaping each special characters.
187 * :mfcmd:`setenv` modulefile command now supports environment variable value
188 containing newline character. Exception is made for *csh* and *tcsh* shells
189 where newline characters are chopped from value. (fix issue #557)
190 * Sort modules in JSON output as done on regular output.
191 * :subcmd:`cachebuild` command now sets the minimal Modules version specified
192 in the cache file magic cookie header to the oldest Modules version
193 compatible with this cache file, rather than the version that generated the
194 cache file. Freshly generated cache files are compatible with Modules 5.3
195 and above.
196 * Doc: improve :ref:`enable-modules-in-shells` guidelines.
197 * Doc: add :ref:`man-path` cookbook recipe.
198 * Doc: add :ref:`other-implementations` document.
199 * Add :subcmd:`update` sub-command, an alias of :subcmd:`reload`
200 * Add :subcmd:`disable` sub-command, an alias of :subcmd:`saverm`
201 * Add :subcmd:`describe` sub-command, an alias of :subcmd:`saveshow`
202 * Add ``--show_hidden`` option, an alias of :option:`--all`
203 * Add :mfcmd:`haveDynamicMPATH` modulefile command
204 * Fix ``use.own`` example modulefile to report when creating local modulefiles
205 directory. (fix issue #576)
206 * Doc: add manual page for :ref:`envml(1)` command. (fix issue #190)
207 * Introduce Emacs addon files to highlight the modulefile syntax. Installation
208 of these files, which is enabled by default, is controlled by the
209 :instopt:`--enable-emacs-addons` and :instopt:`--emacsdatadir` configure
210 options. (contribution from Laurent Besson)
211 * Add :mconfig:`require_via` configuration option that controls whether or not
212 a requirement is considered between a module stored in a modulepath and the
213 loaded module that enables this modulepath. With :ref:`Automated module
214 handling mechanisms<MODULES_AUTO_HANDLING>` enabled, modules stored in a
215 modulepath are unloaded or reloaded when the module enabling this modulepath
216 is changed. :mconfig:`require_via` is disabled by default but everyone
217 willing to hierarchically organize their modulefiles is encouraged to enable
218 this new option. This option can be changed at installation time with
219 :instopt:`--enable-require-via`. When :mconfig:`require_via` is changed with
220 :subcmd:`config` sub-command, it sets the :envvar:`MODULES_REQUIRE_VIA`
221 environment variable.
222 * Install: installation option :instopt:`--enable-new-features` is updated to
223 include :instopt:`--enable-require-via`.
224 * Doc: add :ref:`require-via` design notes.
225 * Skip reload of a *Dependent Reload* module if it is not found after a change
226 in enabled modulepaths. Reload of a not found module is attempted only if it
227 is tagged *super-sticky* or *sticky* and force mode is disabled. Skipped
228 module is considered *Dependent Unload* module.
229 * Script: update :command:`mb` tool to skip test for Modules version below 5.5
230 if Tcl 9 is selected.
231 * Introduce the :mfcmd:`provide` modulefile command that defines module alias
232 over currently evaluating module. This helps convey that the module offers
233 additional functionality or components. (fix issue #539)
234 * Change :mfcmd:`extensions` modulefile command to be an alias over the
235 :mfcmd:`provide` command.
236 * Add the ``provided-alias`` element in the allowed value list of the
237 :mconfig:`avail_output`, :mconfig:`avail_terse_output`,
238 :mconfig:`spider_output` and :mconfig:`spider_terse_output` configuration
239 options. When set, module aliases are included into the output and the
240 *extra match search* mechanism is activated to scan modulefiles to get the
241 module aliases they define.
242 * Doc: add :ref:`provide` design notes.
243 * Introduce ``provide`` and ``provided-alias`` extra specifiers to search
244 modules on :subcmd:`avail`, :subcmd:`spider`, :subcmd:`whatis` and
245 :subcmd:`paths` sub-commands. ``provided-alias`` extra specifier is an alias
246 onto ``provide`` and ``family`` extra specifiers.
247
248 .. _Security policy: https://github.com/envmodules/modules/blob/main/SECURITY.md
249 .. _Modules chat room: https://matrix.to/#/#modules:matrix.org
250
251
252 .. _5.5 release notes:
253
254 Modules 5.5.0 (2024-11-11)
255 --------------------------
256
257 * Init: update ``cmd`` shell initialization script to correctly define
258 :envvar:`MODULESHOME` when installation pathname contains dot character.
259 (fix issue #525 with contribution from V-clone)
260 * Init: add completion for :command:`ml` command on Tcsh shell. (fix issue
261 #416 with contribution from Laurent Besson)
262 * Init: fix completion of :subcmd:`mod-to-sh`'s options on Bash and Tcsh
263 shells.
264 * Fix modulepath file search when libtclenvmodules is disabled and modulepath
265 contains glob characters.
266 * Lib: correct libtclenvmodules to retrieve all user groups on Darwin systems
267 when user is member of more than 16 groups.
268 * Script: output testsuite run progress on :command:`mt` development utility.
269 * Resolve switched-on module prior testing stickiness preservation.
270 * Contrib: fix versions modulefiles generated when
271 :instopt:`--enable-versioning` installation option is set. Use ``--not-req``
272 option on :mfcmd:`module unload<module>` commands to avoid declaring a
273 conflict toward these modules to unload. (fix issue #531)
274 * Add :mfcmd:`hide-modulefile` and :mfcmd:`hide-version` modulerc commands to
275 support modulerc files written for Lmod.
276 * Update :subcmd:`autoinit` sub-command to define :command:`mogui` shell
277 function or alias if `mogui-cmd` command is found in :envvar:`PATH`.
278 * Add the :mconfig:`hide_auto_loaded` configuration option to tag
279 automatically loaded modules ``hidden-loaded``. These modules will not
280 appear on :subcmd:`list` sub-command output unless :option:`--all` option is
281 set. Option is disabled by default and when set, it defines the
282 :envvar:`MODULES_HIDE_AUTO_LOADED` environment variable.
283 * Introduce the ``--modulepath`` option to the :mfcmd:`always-load`,
284 :mfcmd:`depends-on`, :mfcmd:`prereq`, :mfcmd:`prereq-all` and
285 :mfcmd:`prereq-any` modulefile commands. When this option is set, required
286 module should be located in a path listed in the specified list or in an
287 enabled modulepath matching one path of the list. This information is
288 recorded in loaded environment in :envvar:`__MODULES_LMPREREQPATH` variable.
289 * Add :mfcmd:`lsb-release` modulefile command to get certain Linux Standard
290 Base (LSB) information. It accepts to following sub-commands: ``id``,
291 ``codename`` and ``release``.
292 * Add information logging capabilities controlled by two new configuration
293 options: :mconfig:`logger` which defines the command to use to sent
294 information to the log system and :mconfig:`logged_events` which controls
295 the information sent to logs.
296 * :mconfig:`logger` configuration option relies on the :command:`logger`
297 command by default. It can be changed at installation time with
298 :instopt:`--with-logger` and :instopt:`--with-logger-opts` options. When
299 :mconfig:`logger` is changed with :subcmd:`config` sub-command, it sets the
300 :envvar:`MODULES_LOGGER` environment variable. :mconfig:`logger` can be
301 declared as a locked configuration option in :mconfig:`locked_configs`.
302 * :mconfig:`logged_events` configuration option is a list of event names
303 separated by colon character. It is empty by default, thus nothing is logged
304 by default. Allowed event names are ``requested_cmd`` (log module commands
305 directly executed by users), ``requested_eval`` (modulefile evaluations
306 directly asked by users) and ``auto_eval`` (modulefile evaluations
307 automatically triggered). Option value can be changed at installation time
308 with :instopt:`--with-logged-events` option. When :mconfig:`logged_events`
309 is changed with :subcmd:`config` sub-command, it sets the
310 :envvar:`MODULES_LOGGED_EVENTS` environment variable.
311 :mconfig:`logged_events` can be declared as a locked configuration option in
312 :mconfig:`locked_configs`.
313 * Add ``log`` channel to the :mfcmd:`puts` modulefile command. String message
314 passed to :mfcmd:`puts log<puts>` is sent to the :mconfig:`logger` command.
315 * Doc: update :ref:`log-module-command` cookbook recipe with integrated
316 logging feature.
317 * Install: update :file:`configure` script to ignore all ``--with-*`` options
318 if no value is associated to them.
319 * Install: update :file:`configure` script to set option to an empty string if
320 specified with ``--without-*`` argument. Exception is made for
321 :instopt:`--without-icase<--with-icase>` which sets option to the ``never``
322 value.
323 * Introduce ``not:`` prefix for extra specifier and variant criteria on module
324 search context. This prefix allows to negate search criteria on :ref:`Extra
325 match search` mechanism.
326 * Adopt stricter naming rule for variant names. Only characters within the
327 ``A-Za-z0-9_-`` range are allowed. Also, a variant name cannot start with
328 ``-`` (minus) character and the overall name cannot just be a number.
329 * Allow ``+`` and ``~`` characters to be part of module name or version
330 specification as long as the string following them is not a valid variant
331 name (e.g., ``foo/1.2+8``). (fix issue #527)
332 * In case of an issue external to Modules, do not mention at the end of the
333 error stack trace the web link to report this issue. (fix issue #546)
334 * When a modulefile performs a :mfcmd:`module unload<module>` command that
335 fails due to dependent modules loaded, stop unload evaluation right after
336 this failed command unless :option:`--force` option is used.
337 * Exclude sticky modules from the useless requirement unload mechanism as they
338 cannot be unloaded.
339 * Tag automatically loaded module ``auto-loaded`` prior evaluation to be able
340 to query this state during modulefile evaluation with :mfcmd:`module-info
341 tags<module-info>`.
342 * Doc: describe in :ref:`module(1)` man page how to initialize Modules in a
343 Ruby script. (fix issue #535)
344 * Add PowerShell Core (``pwsh``) shell support. (fix issue #326 with
345 contribution from Simon Lukas Märtens)
346 * Lib: adapt Modules Tcl extension library to properly load on Tcl 9.
347 * Doc: describe how to upgrade Modules in :ref:`INSTALL`. (fix issue #544)
348 * Set exit code returned by :file:`modulecmd.tcl` script to ``1`` when a
349 modulefile evaluation fails (modulefile does not exist, is buggy, etc).
350 (fix issue #540)
351 * Disable pager when running :file:`modulecmd.tcl` script for script language
352 (*python*, *perl*, *ruby*, *tcl*, *cmake*, *r* and *lisp*). (fix issue #542)
353 * Update error and warning messages when attempting to unload a module
354 required by another. Distinguish if this module is a requirement of an
355 already loaded or a currently loading module.
356 * Introduce :mconfig:`conflict_unload` configuration option that controls
357 whether or not conflicting modules and their dependent should be unloaded
358 when loading a module. All kind of conflicts are supported: conflicts
359 defined by already loaded modules, conflict declared by loading module
360 through :mfcmd:`conflict`, :mfcmd:`family` or :mfcmd:`module unload<module>`
361 commands. :mconfig:`conflict_unload` also handles the unload of a module
362 that is loaded again but with different variant values or from a different
363 modulepath. :mconfig:`conflict_unload` is disabled by default as it changes
364 behaviors of the :envvar:`automated module handling
365 mode<MODULES_AUTO_HANDLING>`. But everyone is encouraged to enable this new
366 option to benefit from an highly automated experience. This option can be
367 changed at installation time with :instopt:`--enable-conflict-unload`. When
368 :mconfig:`conflict_unload` is changed with :subcmd:`config` sub-command, it
369 sets the :envvar:`MODULES_CONFLICT_UNLOAD` environment variable. Both
370 :mconfig:`auto_handling` and :mconfig:`conflict_unload` options should be
371 enabled to activate *Conflict Unload* automated behavior. (fix issue #242)
372 * When both :mconfig:`auto_handling` and :mconfig:`conflict_unload` options
373 are enabled, all loaded modules matching module specifications set on
374 :mfcmd:`conflict` or :mfcmd:`module unload<module>` commands are unloaded.
375 If both options are not enabled, only one matching loaded module per
376 specification argument of :mfcmd:`module unload<module>` is unloaded. (fix
377 issue #215)
378 * When both :mconfig:`auto_handling` and :mconfig:`conflict_unload` options
379 are enabled, :option:`--force` option set on :subcmd:`load` sub-command is
380 taken into account during the *Conflict Unload* mechanism. For instance, it
381 continues this unload process even if one module unload fails.
382 * Install: installation option :instopt:`--enable-new-features` is updated to
383 include :instopt:`--enable-conflict-unload`.
384 * Fix detection of already loaded module with variant set. If trying to load
385 same module with compatible variant set, a *module is already loaded*
386 message is now returned instead of *another variant is loaded*.
387 * Correctly report module evaluation error in case during the same execution
388 this module was already evaluated and failed silently during a *Requirement
389 Load* mechanism.
390 * Split processing of *Dependent Reload* (DepRe) modules to treat the *DepRe*
391 modules consequence of *Useless Requirement Unload* (UReqUn) modules
392 separately, right before unloading the *UReqUn* modules. As a result,
393 modules in conflict with *UReqUn* modules are unloaded right before *UReqUn*
394 process and reloaded with the other *DepRe* modules.
395 * Handle *UReqUn* process in case of :subcmd:`switch` sub-command after the
396 switch load phase. Unload of these modules were previously occurring at the
397 end of the switch unload phase. Unload of *DepRe* modules consequence of
398 *UReqUn* modules is also moved after switch load phase.
399 * Introduce the *Useless Requirement Unload* (UReqUn) process on
400 :subcmd:`load` sub-command. It eliminates auto loaded modules that were
401 requirements of *Conflict Unload* modules. In case of :subcmd:`switch`
402 sub-command, *UReqUn* modules coming from the switch load phase are handled
403 with *UReqUn* modules coming from switch unload phase.
404 * Rework handling of *DepRe* modules that also are *UReqUn* modules to unload
405 them during the *DepRe* unload phase instead of during *UReqUn* process. As
406 a consequence these modules part of both *DepRe* and *UReqUn* lists are
407 unloaded prior main module action and prior unload of the other *UReqUn*
408 modules. The *DepRe* modules may be also qualified *UReqUn* even if they are
409 not a dependency of a module unloaded in the current processing.
410 * Mix unload of *Dependent Unload* and *Dependent Reload* modules to ensure
411 they are processed in their reverse loading order. As a result, if a module
412 is part of *DepUn* process and some of its requirements are part of *DepRe*
413 process, requirements are unloaded after their dependent modules.
414 * Skip reload of a *Dependent Reload* module if found not loadable (either its
415 requirements are not loaded or a conflict is spotted with loaded
416 environment). Reload is attempted only if module is tagged *super-sticky* or
417 *sticky* and force mode is disabled. Skipped module is considered *Dependent
418 Unload* module.
419 * Reload all Dependent Reload modules after the main load, unload or switch
420 module evaluation rather after the sub module evaluation that triggered the
421 Dependent Reload unload phase.
422 * Dependent Unload modules of Conflict Unload modules are merged into the
423 Dependent Reload module list. An attempt to reload these dependent modules
424 is tried only if their requirements are satisfied by loaded environment.
425 * When a loading module requires a Dependent Unload module, the unload of this
426 module was forced when it was triggered by a Conflict Unload or a
427 switched-off module. The unload of such Dependent Unload module is not
428 forced anymore by default and an error is raised if a loading module
429 requiring the Dependent Unload module is detected.
430 * When unloading Dependent Reload modules, do not force by default this unload
431 unless asked with :option:`--force` option. As a result an error is obtained
432 when trying to reload Dependent Reload modules that conflict with other
433 loaded modules. This error may be by-passed with :option:`--force`
434 command-line option.
435 * Move stickiness check when unloading a module prior processing any automated
436 module handling mechanism. (fix issue #536)
437
438 .. warning:: Variant names are now fully checked instead of just verifying
439 their first character. Only characters within the ``A-Za-z0-9_-`` range are
440 allowed. Variant name cannot start with ``-`` character and the overall
441 name cannot just be a number.
442
443 .. warning:: Existing *versions* modulefiles generated by
444 :instopt:`--enable-versioning` installation option and installed for
445 Modules 4.7 and upward should be manually fixed by adding the ``--not-req``
446 option to the :mfcmd:`module unload<module>` commands present in these
447 modulefiles. Following command should fix these files: ``sed -i "s|module
448 unload|module unload --not-req|" <version_modulefile>``.
449
450
451 .. _5.4 release notes:
452
453 Modules 5.4.0 (2024-02-20)
454 --------------------------
455
456 * Allow to designate module by its full path file name on :mfcmd:`module-tag`,
457 :mfcmd:`module-hide` and :mfcmd:`module-forbid`. (fix issue #485)
458 * Introduce ``tag`` extra specifier to search modules on :subcmd:`avail`,
459 :subcmd:`whatis` and :subcmd:`paths` sub-commands based on tags applied.
460 Tag abbreviation may also be used as extra specifier name.
461 * Add ability to specify multiple names on one extra specifier criterion to
462 select modules matching any of these names (e.g.,
463 ``env:PATH,LD_LIBRARY_PATH``)
464 * Add ability to specify multiple values on one variant criterion to select
465 modules providing any of these variant values (e.g., ``foo=val1,val2``)
466 * Add the ``indesym`` element in the allowed value list of the
467 :mconfig:`list_output` and :mconfig:`list_terse_output` configuration
468 options. When set, symbolic versions are reported as independent elements
469 rather along the loaded module they are attached to.
470 * Add the ``alias`` element in the allowed value list of the
471 :mconfig:`list_output` and :mconfig:`list_terse_output` configuration
472 options. When set, module aliases targeting loaded modules are reported.
473 * Introduce :mconfig:`sticky_purge` configuration option to define behavior
474 when unloading sticky or super-sticky module during a :subcmd:`purge`
475 command. Raise an ``error`` (default) or emit a ``warning`` or be
476 ``silent``. When set, it defines the :envvar:`MODULES_STICKY_PURGE`
477 environment variable. Default value can be changed with
478 :instopt:`--with-sticky-purge` installation option. (fix issue #502)
479 * Introduce :mfcmd:`modulepath-label` modulerc command, which defines label
480 used instead of modulepath directory path in :subcmd:`avail` output.
481 * More than one global rc file can now be specified in :envvar:`MODULERCFILE`
482 or via :mconfig:`rcfile` configuration option.
483 * Add the :mconfig:`unique_name_loaded` configuration option to allow, when
484 enabled, only one module loaded per module name. When set, it defines the
485 :envvar:`MODULES_UNIQUE_NAME_LOADED` environment variable. Default value
486 (disabled) can be changed with :instopt:`--enable-unique-name-loaded`
487 installation option.
488 * Add :ref:`evaluation-errors` design notes.
489 * Add :mconfig:`abort_on_error` configuration option to define module
490 sub-commands that should abort when a module evaluation fails instead of
491 continuing their evaluation sequence. When configuration option is set, it
492 defines the :envvar:`MODULES_ABORT_ON_ERROR` environment variable. Default
493 value can be changed with :instopt:`--with-abort-on-error` installation
494 option.
495 * Add support for :mconfig:`abort_on_error` evaluation behavior on
496 :subcmd:`load`, :subcmd:`mod-to-sh` and :subcmd:`try-load` sub-commands.
497 * Report issue on modulefile when it fails to load an erroneous requirement
498 through :mfcmd:`module try-load<module>` modulefile command.
499 * Doc/Install: modernize modulefile code example in documentation and
500 installed example modulefiles.
501 * Vim: correctly highlight modulefile commands containing a dash character.
502 * Update requirement load error report to place it only under the message
503 block of the module requiring this load. This change helps to better
504 understand the chronology of actions and from where an error occurs.
505 * Do not report requirement load error when an alternative requirement module
506 is found and loaded afterward. (fix issue #509)
507 * Do not render an error exit code on multi-module option requirement when
508 one module option fails to load but another does. (fix issue #510)
509 * Do not report *module not found* error when loading a requirement if an
510 alternative requirement module is found and loaded afterward. (fix issue
511 #511)
512 * Add ``--glob`` option to :mfcmd:`remove-path` modulefile command in order to
513 remove any values in variable matching a glob-style pattern.
514 * Record module specification on which loaded module stickiness applies in
515 :envvar:`__MODULES_LMSTICKYRULE` environment variable. It helps to determine
516 if stickiness is satisfied when changing loaded modules. Which was not
517 working correctly for virtual modules. (fix issue #506)
518 * Silently ignore cache file when it requires a greater Modules version. (fix
519 issue #515)
520 * Doc: move :ref:`modulefile(5)` man page in section 5. (fix issue #518 with
521 contribution from Laurent Chardon)
522 * Add :mconfig:`source_cache` configuration option to cache files evaluated in
523 modulefiles with ``source`` Tcl command. Files sourced multiple times are
524 only read once when option is enabled. :mconfig:`source_cache` is disabled
525 by default. When set, it defines the :envvar:`MODULES_SOURCE_CACHE`
526 environment variable. Default value can be changed with
527 :instopt:`--enable-source-cache` installation option.
528 * Add support for :mconfig:`abort_on_error` evaluation behavior on
529 :subcmd:`unload` sub-command.
530 * A modulefile is unloaded anyway even if an evaluation error occurs when
531 :option:`--force` option is used on :command:`ml`, :subcmd:`purge`,
532 :subcmd:`reload`, :subcmd:`reset`, :subcmd:`restore`, :subcmd:`stash`,
533 :subcmd:`stashpop`, :subcmd:`switch` and :subcmd:`unload` sub-commands. To
534 forbid the unload of a modulefile it is recommended to tag it
535 ``super-sticky`` with :mfcmd:`module-tag` command.
536 * Disable :mconfig:`abort_on_error` when :option:`--force` option is used. In
537 this case, behavior is to continue when an error occurs.
538 * Add support for :mconfig:`abort_on_error` evaluation behavior on
539 :command:`ml` command. *Abort on error* behavior is on by default with
540 :command:`ml`. Removing it from :mconfig:`abort_on_error`'s value enables
541 the *continue on error* behavior.
542 * Add support for :mconfig:`abort_on_error` evaluation behavior on
543 :subcmd:`reload` command. *Abort on error* behavior is on by default with
544 :subcmd:`reload`. Removing it from :mconfig:`abort_on_error`'s value enables
545 the *continue on error* behavior.
546 * Add support for :mconfig:`abort_on_error` evaluation behavior on
547 :subcmd:`purge` sub-command.
548 * Add support for :mconfig:`abort_on_error` evaluation behavior on unload
549 phase of :subcmd:`switch` command. *Abort on error* behavior is on by
550 default there. Removing ``switch_unload`` from :mconfig:`abort_on_error`'s
551 value enables the *continue on error* behavior.
552 * Add support for :mconfig:`abort_on_error` evaluation behavior on
553 :subcmd:`switch` command. *Abort on error* behavior is applied if ``switch``
554 value is set in :mconfig:`abort_on_error` and either switch unload or switch
555 load phase fails.
556 * Install: installation option :instopt:`--enable-new-features` is updated to
557 enable *abort on error* behavior on :subcmd:`load` and :subcmd:`switch`
558 sub-commands.
559 * Lib: slightly adapt code of Modules Tcl extension library to properly build
560 against Tcl 9.0.
561 * Adapt alias unset shell code for *sh*-kind shells to avoid errors when alias
562 to unset is not defined.
563 * Adapt function unset shell code for *sh*-kind shells to avoid errors when
564 function to unset is not defined.
565 * No output of *unload of switched-off failed* and *load of switched-on
566 failed* error messages when :mfcmd:`module switch<module>` command is run
567 from a modulefile.
568 * No *Switching* block message report when :mfcmd:`module switch<module>`
569 command is run from a modulefile.
570 * Report all error and warning messages locally under *Loading* or *Unloading*
571 block message rather reporting some of them under the block message of the
572 main action. These errors and warnings are thus reported where they occur.
573 * Report switched-on load failure as error rather warning.
574 * Report switched-on module locating or access issues only once.
575 * Report conflict error message when it occurs rather than after modulefile
576 evaluation.
577 * Update conflict error message to report all conflicting modules name and
578 version rather conflict module specification.
579 * Fix conflict error check to avoid reporting both *unloading conflict failed*
580 and *conflict is loading* messages.
581 * Raise an error and stop modulefile evaluation when :mfcmd:`module
582 switch<module>` command fails unless if :option:`--force` option is set.
583 * When a *useless requirement unload* fails, do not increase error count as
584 this failure is reported as a warning and main unload process is not
585 affected.
586 * Path element equals to delimiter character is allowed on
587 :mfcmd:`append-path` and :mfcmd:`prepend-path` modulefile commands. (fix
588 issue #522)
589 * Add ``bash-eval`` shell mode to :mfcmd:`source-sh` modulefile command and
590 :subcmd:`sh-to-mod` sub-command. With this mode, the generated output of the
591 bash shell script is evaluated to get the environment changes instead of
592 sourcing this script. (fix issue #519)
593 * Add ``--ignore`` option to :mfcmd:`source-sh` modulefile command to define
594 shell elements changed by shell script that should be ignored. (fix issue
595 #503)
596 * Init: Improve Tcsh shell completion script to complete against existing
597 files when pattern starts with ``/``, ``.`` or ``~/``. (fix issue #523)
598 * Add ``--user`` option to :mfcmd:`module-forbid`, :mfcmd:`module-hide` and
599 :mfcmd:`module-tag` modulefile commands to forbid, hide or tag only if user
600 is listed in the value of this new option. (fix issue #520 with contribution
601 from Jérémy Déchard)
602 * Add ``--group`` option to :mfcmd:`module-forbid`, :mfcmd:`module-hide` and
603 :mfcmd:`module-tag` modulefile commands to forbid, hide or tag only if one
604 user's group is listed in the value of this new option. (fix issue #520 with
605 contribution from Jérémy Déchard)
606
607
608 .. _5.3 release notes:
609
610 Modules 5.3.1 (2023-06-27)
611 --------------------------
612
613 * Fix additional `ShellCheck`_ warning reports over sh and bash shell scripts.
614 * Install: distribute ``ChangeLog`` as a zipped file to reduce installation
615 size. As a consequence, :command:`gzip` becomes a requirement when building
616 Modules from git repository.
617 * Install: adapt RPM spec file to install module initialization script for
618 fish as configuration snippet for this shell.
619 * Fix extra specifier search to evaluate module matching requirement query.
620 (fix issue #494)
621 * Fix extra specifier requirement search when module searched is also defining
622 a requirement and is the sole module to define it. (fix issue #495)
623 * Script: update :command:`pre-commit` and :command:`commit-msg` git hook
624 scripts to use `Hunspell`_ as spell checker instead of Aspell.
625 * Fix unaligned :subcmd:`list` output when 100 or more modules are loaded.
626 (fix issue #496)
627 * Fix extra specifier search when an identical module name and version is
628 available in several modulepaths. (fix issue #497)
629 * Do not match module commands with :mfcmd:`--not-req<module>` option set on
630 ``require`` or ``incompat`` extra specifier queries. (fix issue #498)
631 * When one variant is specified multiple times on search context
632 (:subcmd:`avail`, :subcmd:`paths` or :subcmd:`whatis` sub-commands),
633 available modules returned are those providing all variant values set. (fix
634 issue #499)
635 * Add the ``indesym`` element in the allowed value list of the
636 :mconfig:`avail_output` and :mconfig:`avail_terse_output` configuration
637 options. When set, symbolic versions are reported as independent elements
638 rather along the module or directory they are attached to.
639 * Init: fix completion scripts to report module symbolic versions and aliases
640 among available modules. (fix issue #500)
641
642 .. _Hunspell: https://hunspell.github.io/
643
644
645 Modules 5.3.0 (2023-05-14)
646 --------------------------
647
648 * Add :ref:`module-cache` design notes.
649 * Add :subcmd:`cachebuild` sub-command to create cache for modulepaths
650 enabled or specified on the command line. Cache files are named
651 ``.modulecache`` and stored at the root of modulepath directories.
652 * Add :subcmd:`cacheclear` sub-command to delete cache file in all enabled
653 modulepaths.
654 * Use cache file if available rather search the content of modulepath
655 directories when searching for modules (e.g., during :subcmd:`avail`,
656 :subcmd:`load`, :subcmd:`display`, etc).
657 * Script: add cache-enabled version of *avail*, *whatis* and *load* tests on
658 :command:`mb` benchmark utility.
659 * Add the :mconfig:`ignore_cache` configuration option to ignore module cache
660 file. Option is disabled by default and when set, it defines
661 :envvar:`MODULES_IGNORE_CACHE` environment variable.
662 * Add :option:`--ignore-cache` command-line switch to enable
663 :mconfig:`ignore_cache` configuration option and ignore module cache file
664 for current execution.
665 * Add :mconfig:`cache_buffer_bytes` configuration option to define buffer size
666 when reading or writing cache files. Option is set to ``32768`` by default.
667 When set it defines :envvar:`MODULES_CACHE_BUFFER_BYTES` environment
668 variable.
669 * Add :mconfig:`cache_expiry_secs` configuration option that defines the
670 number of seconds a cache file is considered valid after being generated.
671 Option is set to ``0`` by default which means cache files never expire. When
672 option is set it defines :envvar:`MODULES_CACHE_EXPIRY_SECS` environment
673 variable.
674 * Modulefiles and directories that are not accessible by everyone are not
675 recorded in cache file. A *limited access* directive is recorded instead to
676 indicate these modulefiles have to be tested and directories have to be
677 walked down to determine what the running user can access.
678 * Doc: update :ref:`reduce-io-load` cookbook recipe with module cache
679 description.
680 * Correctly apply extra tag set when loading a module whose variant has value
681 automatically set. (fix issue #484)
682 * Catch collection directory creation error and report appropriate message.
683 (fix issue #482)
684 * Fix :mfcmd:`source-sh` and :subcmd:`sh-to-mod` shell alias translation when
685 used with new *fish* shell version (3.6).
686 * Install: allow to build Modules from a short-depth git repository. (fix
687 issue #486)
688 * Install: ensure git log format is not influenced by user's configuration in
689 :command:`gitlog2changelog.py`. (fix issue #487)
690 * Init: fix bash shell completion script to be able to complete full name of
691 available modules. (fix issue #490)
692 * Install: move license name to SPDX format in RPM spec file.
693 * Doc: add :ref:`extra-match-search` design notes.
694 * Introduce *extra match search* mechanism that evaluates available
695 modulefiles during a module search to find those matching an extra query
696 on a variant value, a dependency or an environment variable definition.
697 During this specific evaluation, modulefiles are interpreted in *scan*
698 mode.
699 * ``scan`` string is returned by :mfcmd:`module-info mode<module-info>` when
700 queried during a *scan* modulefile evaluation.
701 * Add the ``variant`` element in the allowed value list of the
702 :mconfig:`avail_output` and :mconfig:`avail_terse_output` configuration
703 options. When set, variants and their possible values are reported along the
704 module they are associated to on :subcmd:`avail` command output. Adding
705 variant information to this output activates the *extra match search*
706 mechanism that scan modulefiles to find variants they define. (fix issue
707 #407)
708 * Apply graphic rendition of default version (``de`` SGR key) to default
709 variant value on either :subcmd:`list` and :subcmd:`avail` command output.
710 * Apply either loaded or auto-loaded graphic rendition to the loaded variant
711 value on :subcmd:`avail` command output.
712 * Update :subcmd:`avail`, :subcmd:`paths` and :subcmd:`whatis` sub-commands to
713 take into account variant set in module specification. Available modules are
714 filtered with *extra match search* mechanism to only return those matching
715 the variant specification.
716 * Update :subcmd:`avail`, :subcmd:`paths` and :subcmd:`whatis` sub-commands to
717 accept module specification with just a variant set (no module name and
718 version). Available modules are filtered with *extra match search* mechanism
719 to only return those matching the variant specification.
720 * Update :subcmd:`list` sub-command to accept module specification with just a
721 variant set (no module name and version). Loaded modules are filtered to
722 only return those matching the variant specification.
723 * Highlight searched variant name and value (``hi`` SGR key) on either
724 :subcmd:`list` and :subcmd:`avail` command output.
725 * Doc: add :ref:`Extra match search` description in :ref:`module(1)` man page.
726 * Introduce *extra specifiers* to query content of modulefiles. *Extra
727 specifiers* can be specified with *element:name* syntax as part of module
728 specification on module search commands (:subcmd:`avail`, :subcmd:`paths`
729 and :subcmd:`whatis`). For instance with the ``module avail
730 append-path:PATH`` command, all modulefiles defining the ``append-path``
731 command on ``PATH`` environment variable are returned.
732 * Add ``variant`` extra specifier to query modulefile variant definitions.
733 (fix issue #408)
734 * Add ``setenv``, ``unsetenv``, ``append-path``, ``prepend-path``,
735 ``remove-path`` and ``pushenv`` extra specifiers to query modulefile
736 environment variable definitions. The extra specifier alias ``envvar`` may
737 also be used to query any of these modulefile commands.
738 * Add ``complete`` and ``uncomplete`` extra specifiers to query modulefile
739 shell completion definitions.
740 * Add ``set-alias`` and ``unset-alias`` extra specifiers to query modulefile
741 shell alias definitions.
742 * Add ``set-function`` and ``unset-function`` extra specifiers to query
743 modulefile shell function definitions.
744 * Add ``chdir`` extra specifier to query modulefile current working directory
745 change definitions.
746 * Add ``family`` extra specifier to query modulefile family definitions.
747 * Add ``prereq``, ``prereq-any``, ``prereq-all``, ``depends-on``,
748 ``always-load``, ``load``, ``load-any``, ``try-load``, ``switch`` and
749 ``switch-on`` extra specifiers to query modulefile requirement definitions.
750 The extra specifier alias ``require`` may also be used to query any of these
751 modulefile commands.
752 * Add ``conflict``, ``unload``, ``switch`` and ``switch-off`` extra specifiers
753 to query modulefile incompatibility definitions. The extra specifier alias
754 ``incompat`` may also be used to query any of these modulefile commands.
755 * Requirement and incompatibility extra specifiers accept module specification
756 as value.
757 * Doc: add :ref:`Extra specifier` description in :ref:`module(1)` man page.
758 * Mark loaded modules as qualified for refresh evaluation when they send
759 content to ``stdout`` or ``prestdout`` channels with :mfcmd:`puts`
760 modulefile command. (fix issue #488)
761 * Add the :mconfig:`ignore_user_rc` configuration option to skip evaluation of
762 user-specific module rc file. Option is disabled by default and when set, it
763 defines :envvar:`MODULES_IGNORE_USER_RC` environment variable.
764 * Add :option:`--ignore-user-rc` command-line switch to enable
765 :mconfig:`ignore_user_rc` configuration option and ignore user-specific
766 module rc file for current execution.
767 * Add the ``variantifspec`` element in the allowed value list of the
768 :mconfig:`avail_output` and :mconfig:`avail_terse_output` configuration
769 options. Set this new element in the default value list of both options.
770 When set and if a variant is specified in search query, variants and their
771 possible values are reported along the module they are associated to on
772 :subcmd:`avail` command output.
773 * Accept value starting with ``+`` or ``-`` characters on
774 :option:`--output`/:option:`-o` command-line switches to indicate value
775 should respectively be appended to or subtracted from current configuration
776 option value.
777 * Accept value starting with ``+`` or ``-`` characters on
778 :mconfig:`avail_output`, :mconfig:`avail_terse_output`,
779 :mconfig:`list_output`, :mconfig:`list_terse_output`, :mconfig:`colors`,
780 :mconfig:`protected_envvars`, :mconfig:`shells_with_ksh_fpath`,
781 :mconfig:`tag_abbrev`, :mconfig:`tag_color_name`,
782 :mconfig:`variant_shortcut` configuration options to indicate value
783 should respectively be appended to or subtracted from current configuration
784 option value.
785 * Fix :subcmd:`switch` sub-command not to unload *sticky* module when
786 switched-on module does not exist. (fix issue #492)
787
788
789 .. _5.2 release notes:
790
791 Modules 5.2.0 (2022-11-08)
792 --------------------------
793
794 * Introduce the ``--optional`` option on :mfcmd:`prereq`, :mfcmd:`prereq-all`,
795 :mfcmd:`depends-on` and :mfcmd:`always-load` modulefile commands. Expressed
796 optional dependency is considered satisfied even if modulefile is not
797 loaded. If optional requirement is loaded afterward, dependent module is
798 automatically reloaded, unless if the :mconfig:`auto_handling` configuration
799 option is disabled.
800 * A dependency expressed in modulefile with :mfcmd:`module try-load<module>`
801 command is considered optional. Dependent module is automatically reloaded
802 if the optional requirement is loaded afterward, unless if the
803 :mconfig:`auto_handling` configuration option is disabled.
804 * Raise error in case of unknown or misplaced option set on :mfcmd:`prereq`,
805 :mfcmd:`prereq-all`, :mfcmd:`depends-on` or :mfcmd:`always-load` modulefile
806 commands.
807 * Add the :option:`--timer` command-line switch to report the total execution
808 time of the :command:`module` command. Also report the execution time of
809 every internal procedure calls when mixed with :option:`--debug` option.
810 * Init: move :envvar:`PATH` setup (to locate Modules' binaries location) from
811 shell initialization scripts to the :subcmd:`autoinit` sub-command. (fix
812 issue #462)
813 * Init: move :envvar:`MANPATH` setup (to locate Modules' man-pages) from
814 shell initialization scripts to the :subcmd:`autoinit` sub-command. (fix
815 issue #462)
816 * Init: move shell completion setup from shell initialization scripts to the
817 :subcmd:`autoinit` sub-command. (fix issue #462)
818 * Enclose installation path references in shell code produced by
819 :subcmd:`autoinit`, in initialization scripts and Makefiles to guaranty
820 correct evaluation in case these paths contain a space character. Note that
821 the quarantine mechanism is not compatible with such installation paths.
822 * Fix :mfcmd:`source-sh` and :subcmd:`sh-to-mod` when used with *fish* shell
823 script if ``regex-easyesc`` fish option is enabled. (fix issue #463)
824 * Add the :mconfig:`protected_envvars` configuration option to define a list
825 of environment variables that cannot be modified by modulefile commands.
826 When set, :mconfig:`protected_envvars` defines
827 :envvar:`MODULES_PROTECTED_ENVVARS` environment variable. (fix issue #429
828 with contribution from Adrien Cotte)
829 * Introduce the :subcmd:`lint` sub-command to statically analyze syntax of
830 modulefiles, modulerc and global/user rc. (fix issue #451)
831 * Add the :mconfig:`tcl_linter` configuration option to define the program
832 used to analyze files with :subcmd:`lint` sub-command. This option is set to
833 ``nagelfar.tcl`` by default. When changed from default value, the
834 :envvar:`MODULES_TCL_LINTER` environment variable is defined. Default value
835 can be changed with :instopt:`--with-tcl-linter` and
836 :instopt:`--with-tcl-linter-opts` installation options.
837 * Add the :instopt:`--enable-nagelfar-addons` installation option (enabled by
838 default) to install specific syntax databases and plugins to lint
839 modulefiles, modulerc and global/user rc with `Nagelfar`_. These files are
840 installed in the directory designated by the :instopt:`--nagelfardatadir`
841 (``DATAROOTDIR/nagelfar`` by default).
842 * Doc: add :ref:`lint-sub-command` design notes.
843 * Install: use :command:`install` command rather :command:`cp` or
844 :command:`mkdir` to install Modules and guaranty consistent permission modes
845 on deployed files.
846 * Also unset :mfcmd:`pushenv` value stacks on :subcmd:`clear` sub-command.
847 * Doc: add :ref:`mod-to-sh-sub-command` design notes.
848 * Introduce the :subcmd:`mod-to-sh` sub-command to translate designated
849 modulefile(s) into code for specified shell. (fix issue #447)
850 * Make :subcmd:`source` sub-command accepts modulefile specification as
851 argument. If argument does not correspond to a file path, search it among
852 available modulefiles. (fix issue #424)
853 * Doc: clarify :mfcmd:`set-alias` only define shell alias and not shell
854 function.
855 * Add the ability to filter the list of collections returned by
856 :subcmd:`savelist` sub-command. Filtering pattern is matched in a case
857 insensitive manner by default.
858 * Add support for :option:`--starts-with` and :option:`--contains` options on
859 :subcmd:`savelist` sub-command.
860 * Highlight all search patterns on :subcmd:`list` sub-command output instead
861 of only the first one..
862 * Highlight all search patterns on :subcmd:`savelist` sub-command output.
863 * Add support for :option:`--all` option on :subcmd:`savelist` sub-command not
864 to limit result to the collection matching currently defined
865 :mconfig:`collection_target`.
866 * Doc: add :ref:`Shell support` section in :ref:`modulefile(5)` man page to
867 describe how shells support the different kind of environment changes that
868 can be defined in modulefiles.
869 * Record during :subcmd:`autoinit` sub-command the initial environment state
870 in :envvar:`__MODULES_LMINIT`. Enabled modulepaths and loaded modulefiles
871 through :file:`modulespath` and :file:`initrc` initialization configuration
872 files are recorded in this new environment variable.
873 * Add :subcmd:`reset` sub-command to restore initial environment. It takes
874 recorded environment in :envvar:`__MODULES_LMINIT` and restores it.
875 * Initial environment is restored when collection name specified on
876 :subcmd:`restore` sub-command equals ``__init__``.
877 * When no argument is provided to :subcmd:`restore` sub-command and if
878 *default* collection does not exist, initial environment is restored.
879 * Initial environment content is displayed when collection name specified on
880 :subcmd:`saveshow` sub-command equals ``__init__``.
881 * When no argument is provided to :subcmd:`saveshow` sub-command and if
882 *default* collection does not exist, initial environment content is
883 displayed.
884 * Add :mconfig:`reset_target_state` configuration option to determine behavior
885 of :subcmd:`reset` sub-command. When set to ``__init__`` (default value)
886 initial environment is restored. When set to ``__purge__``, a
887 :subcmd:`purge` sub-command is performed. Any other value, corresponds to
888 the name of a collection to :subcmd:`restore`. When set,
889 :mconfig:`reset_target_state` defines :envvar:`MODULES_RESET_TARGET_STATE`
890 environment variable.
891 * Doc: add :ref:`initial-environment` design notes.
892 * Unload *sticky* modules on :subcmd:`restore` and :subcmd:`reset`
893 sub-commands to fully set environment in collection or initial state.
894 * Testsuite: add *lint* testsuite to validate syntax of shell and Tcl scripts
895 of this project. This testsuite can be invoked with ``make testlint`` or
896 ``script/mt lint``. sh, bash and ksh scripts are checked with `ShellCheck`_
897 tool and tcl scripts are checked with `Nagelfar`_.
898 * Update :file:`modulecmd.tcl` code and add Nagelfar inline comments to fix
899 linter reports.
900 * Script: add usage message and support for ``-h``/``--help`` option on
901 :command:`mrel`, :command:`mpub`, :command:`mt`, :command:`mtreview`,
902 :command:`nglfar2ccov`, :command:`mb` and :command:`mlprof` development
903 utilities.
904 * Doc: describe :command:`script/mt` and :command:`script/mb` utilities in
905 :ref:`CONTRIBUTING` guide.
906 * Fix `ShellCheck`_ error, warning and info reports over all sh, bash and ksh
907 shell scripts. (fix issue #470 with contribution from Lukáš Zaoral)
908 * Init: update profile script for sh-like shells to only source sh or bash
909 initialization script when BASH environment variable is found set. (fix
910 issue #473)
911 * Add :subcmd:`stash` sub-command to save current environment and restore
912 initial one.
913 * Add :subcmd:`stashpop` sub-command to restore stash collection then delete
914 this collection file.
915 * Add :subcmd:`stashrm` sub-command to delete stash collection file.
916 * Add :subcmd:`stashshow` sub-command to display stash collection file.
917 * Add :subcmd:`stashclear` sub-command to delete all stash collection files.
918 * Add :subcmd:`stashlist` sub-command to list all stash collection files.
919 * Update :subcmd:`savelist` sub-command to filter out stash collections unless
920 if :option:`--all` option is set.
921 * Doc: ensure current user environment does not break logging system in
922 :ref:`log-module-command` recipe. (fix issue #475)
923 * Rename the default git branch from *master* to *main* to use inclusive
924 terminology.
925 * Mark loaded modules that could benefit from a refresh evaluation in the
926 :envvar:`__MODULES_LMREFRESH` environment variable.
927 * Optimize :subcmd:`refresh` sub-command to only evaluate loaded modules that
928 defines volatile environment changes (shell completion, alias or function).
929 (fix issue #477)
930 * Add :sitevar:`modulefile_extra_cmds` hook variable that could be defined in
931 :file:`siteconfig.tcl` file to define specific commands in modulefile
932 interpreter context. :sitevar:`modulefile_extra_cmds` is a list of command
933 name and relative procedure pairs. (fix issue #286)
934 * Add :sitevar:`modulefile_extra_vars` hook variable that could be defined in
935 :file:`siteconfig.tcl` file to define specific variables in modulefile
936 interpreter context. :sitevar:`modulefile_extra_vars` is a list of variable
937 name and value pairs. (fix issue #286)
938 * Add :sitevar:`modulerc_extra_cmds` hook variable that could be defined in
939 :file:`siteconfig.tcl` file to define specific commands in modulerc
940 interpreter context. :sitevar:`modulerc_extra_cmds` is a list of command
941 name and relative procedure pairs. (fix issue #286)
942 * Add :sitevar:`modulerc_extra_vars` hook variable that could be defined in
943 :file:`siteconfig.tcl` file to define specific variables in modulerc
944 interpreter context. :sitevar:`modulerc_extra_vars` is a list of variable
945 name and value pairs. (fix issue #286)
946 * Doc: Add :ref:`Site-specific configuration` section in :ref:`module(1)` man
947 page.
948 * Doc: extend :ref:`Collections` section with examples in :ref:`module(1)` man
949 page.
950
951 .. _Nagelfar: http://nagelfar.sourceforge.net/
952 .. _ShellCheck: https://www.shellcheck.net/
953
954
955 .. _5.1 release notes:
956
957 Modules 5.1.1 (2022-05-31)
958 --------------------------
959
960 * Install: add :command:`rpmlint` rc configuration file to filter false
961 positive warning messages.
962 * Install: better guess ``libdir64`` and ``libdir32`` directory locations
963 when ``libdir`` does not end with *64* but contains *64*.
964 * Install: update RPM spec file to move libtclenvmodules in an
965 environment-modules directory under ``libdir``.
966 * Fix rendering of loading or unloading module designation when configured
967 color palette does not set the ``hi`` color key. (fix issue #455)
968 * Remove the *already loaded* message displayed when verbosity level is higher
969 or equal to ``verbose2`` if new tags are applied to the loaded module. (fix
970 issue #456)
971 * Report a global known error when current working directory cannot be
972 retrieved due to the removal of this directory. (fix issue #457)
973 * Update tags set through :mfcmd:`prereq` command on all already loaded
974 requirements. (fix issue #459)
975 * Update module designation with the tags set by reloading dependent module.
976 (fix issue #460)
977 * Install: include the ``lib/config.guess`` and ``lib/config.sub`` scripts in
978 distribution tarball if generated by :command:`autoreconf`.
979 * Install: call ``git`` command in ``Makefile`` only if the definitions of
980 ``version.inc`` need to get built or refreshed.
981
982
983 Modules 5.1.0 (2022-04-30)
984 --------------------------
985
986 * Allow to declare :mfcmd:`variant` with no list of accepted value. Such
987 variant accepts any value specified. (fix issue #405)
988 * Add the :mconfig:`redirect_output` configuration option to control on *sh*,
989 *bash*, *ksh*, *zsh* and *fish* shells whether or not the output of the
990 :command:`module` function should be redirected from stderr to stdout. When
991 set, :mconfig:`redirect_output` defines :envvar:`MODULES_REDIRECT_OUTPUT`
992 environment variable.
993 * Introduce the :option:`--redirect`/:option:`--no-redirect` command-line
994 switches to supersede the value of the :mconfig:`redirect_output`
995 configuration option on *sh*, *bash*, *ksh*, *zsh* and *fish* shells. (fix
996 issue #410)
997 * Add the ``--return-value`` option to the :mfcmd:`getenv` and
998 :mfcmd:`getvariant` modulefile commands to force to return the value of
999 respectively designated environment variable or variant when modulefile is
1000 evaluated in *display* mode. (fix issue #422)
1001 * Introduce the :subcmd:`state` sub-command to display Modules states.
1002 * Add the ``supported_shells`` state to get the list of the shells that are
1003 supported by :file:`modulecmd.tcl` through the :subcmd:`state` sub-command .
1004 (fix issue #426)
1005 * Filter out the variables intended for Modules private usage when processing
1006 the environment changes made by a script evaluated by :subcmd:`sh-to-mod`
1007 sub-command or :mfcmd:`source-sh` modulefile command. (fix issue #427)
1008 * Doc: add :ref:`control-mode-behaviors` design notes.
1009 * Doc: add :ref:`add-new-config-option` design notes.
1010 * Set a `Code of conduct`_ for the project and its community based on the
1011 widely adopted Contributor Covenant.
1012 * Doc: add :ref:`add-new-sub-command` design notes.
1013 * Add the ``--remove-on-unload`` option to the :mfcmd:`remove-path` to also
1014 remove value when modulefile is unloaded.
1015 * Raise error when an unknown option is set on :mfcmd:`module use<module>` or
1016 :mfcmd:`module unuse<module>` modulefile command.
1017 * Rework emitted debug messages to remove obvious ones and systematically
1018 report each modulefile command processed with their arguments.
1019 * Add the ``--append-on-unload`` option to the :mfcmd:`remove-path` and
1020 :mfcmd:`module unuse<module>` modulefile commands to append back when
1021 modulefile is unloaded the value removed at load time or a specific value
1022 set after this option.
1023 * Add the ``--prepend-on-unload`` option to the :mfcmd:`remove-path` and
1024 :mfcmd:`module unuse<module>` modulefile commands to prepend back when
1025 modulefile is unloaded the value removed at load time or a specific value
1026 set after this option.
1027 * Add the ``--noop-on-unload`` option to the :mfcmd:`unsetenv`,
1028 :mfcmd:`remove-path` and :mfcmd:`module unuse<module>` modulefile commands
1029 to perform no operation when modulefile is unloaded.
1030 * Add the ``--unset-on-unload`` option to the :mfcmd:`unsetenv` modulefile
1031 command to also unset environment variable when modulefile is unloaded.
1032 * Add the ``--set-if-undef`` option to the :mfcmd:`setenv` modulefile command
1033 to set environment variable when modulefile is loaded only this variable is
1034 not yet defined.
1035 * Install: add the :instopt:`--with-bashcompletiondir`,
1036 :instopt:`--with-fishcompletiondir` and :instopt:`--with-zshcompletiondir`
1037 installation options to install shell completion scripts in their
1038 system-wide location. (fix issue #428)
1039 * Doc: add :ref:`lmod-tcl-modulefile-compat` design notes.
1040 * Introduce the ``add-property``, ``remove-property`` and ``extensions``
1041 modulefile commands for compatibility with Lmod Tcl modulefiles. These
1042 commands are evaluated as a *no-operation* command.
1043 * Introduce the :mfcmd:`prereq-any` modulefile command for compatibility with
1044 Lmod Tcl modulefiles. :mfcmd:`prereq-any` is an alias of :mfcmd:`prereq`
1045 command.
1046 * Produce a clear error message when wrong number of argument is received by
1047 :mfcmd:`prereq` command.
1048 * Doc: describe :mfvar:`ModulesVersion` in *Modules Variables* section in
1049 :ref:`modulefile(5)` man page.
1050 * Set ``ModuleVersion`` as an alias over :mfvar:`ModulesVersion` modulefile
1051 variable for compatibility with Lmod Tcl modulefiles.
1052 * Doc: describe :mfcmd:`reportError` and :mfcmd:`reportWarning` modulefile
1053 commands.
1054 * Add the :mfcmd:`require-fullname` modulefile command for compatibility with
1055 Lmod Tcl modulefiles. This command aborts modulefile *load* evaluation if
1056 modulefile's name is not fully specified.
1057 * Add the :mfcmd:`prereq-all` modulefile command, alias over the
1058 :mfcmd:`prereq` command which acts as an *AND* operation when multiple
1059 modulefiles are specified.
1060 * Add the :mfcmd:`depends-on` modulefile command, alias over the
1061 :mfcmd:`prereq-all` command for compatibility with Lmod Tcl modulefiles.
1062 * Introduce the ``keep-loaded`` :ref:`module tag<Module tags>` that avoids an
1063 auto-loaded module to get automatically unloaded when its dependent modules
1064 are getting unloaded. Update default :mconfig:`tag_abbrev` configuration
1065 option to add an abbreviation for the new tag (``kL``) and default light and
1066 dark color palettes.
1067 * Add the :mfcmd:`always-load` modulefile command for compatibility with Lmod
1068 Tcl modulefiles. This command loads designated modulefile and applies the
1069 ``keep-loaded`` tag to it.
1070 * Add the :subcmd:`load-any` sub-command and :mfcmd:`module load-any<module>`
1071 modulefile command for compatibility with Lmod Tcl modulefiles. This command
1072 loads one modulefile from specified list.
1073 * Add support for ``--not-req`` option on :mfcmd:`module try-load<module>` and
1074 :mfcmd:`module load-any<module>` modulefile commands.
1075 * Doc: add :ref:`magic-cookie-check` design notes.
1076 * Add the :mconfig:`mcookie_check` configuration option that control whether
1077 the magic cookie at the start of modulefile (i.e., ``#%Module`` file
1078 signature) need to get checked or not. When set to ``eval`` the number of
1079 file checks is significantly reduced when walking through modulepaths to
1080 search for modulefiles. Default value for this option is overridden by the
1081 :envvar:`MODULES_MCOOKIE_CHECK` environment variable.
1082 * Doc: describe :mfcmd:`puts` Tcl command and its specific feature when used
1083 in modulefile.
1084 * Create the ``prestdout`` channel for :mfcmd:`puts` modulefile command to be
1085 able to send content that will be evaluated in current shell session prior
1086 any other content. (fix issue #432)
1087 * Add the :mfcmd:`family` modulefile command for compatibility with Lmod Tcl
1088 modulefiles. This command defines family name as a module alias over
1089 currently loading module and express a conflict over this name to ensure
1090 only one member of a family can be loaded in user environment.
1091 :mfcmd:`family` also defines the :envvar:`MODULES_FAMILY_\<NAME\>` and
1092 :envvar:`LMOD_FAMILY_\<NAME\>` environment variables.
1093 * Doc: add :ref:`reduce-io-load` cookbook recipe.
1094 * Add the ability to filter the list of loaded modules returned by
1095 :subcmd:`list` sub-command. Filtering pattern could be part of module name,
1096 symbolic version or alias and is matched in a case insensitive manner by
1097 default. It could also leverage the :ref:`Advanced module version
1098 specifiers` syntax.
1099 * Add support for :option:`--starts-with` and :option:`--contains` options on
1100 :subcmd:`list` sub-command.
1101 * Doc: add :ref:`shell-completion` design notes.
1102 * Introduce :mfcmd:`complete` and :mfcmd:`uncomplete` modulefile commands to
1103 respectively enable and disable shell completion for a given command name.
1104 *bash*, *tcsh* and *fish* shells are supported.
1105 * Track shell completion changes of *bash*, *tcsh* and *fish* shell scripts on
1106 :subcmd:`sh-to-mod` sub-command and :mfcmd:`source-sh` modulefile command.
1107 * Fix typos found in code, tests and documentation. (contribution from Dimitri
1108 Papadopoulos Orfanos)
1109 * Update the :subcmd:`sh-to-mod` and :mfcmd:`source-sh` mechanisms to support
1110 nested function definition on fish shell.
1111 * Fix the :subcmd:`sh-to-mod` and :mfcmd:`source-sh` mechanisms to correctly
1112 detect functions with a ``_`` character in their name on fish shell.
1113 * Update the :command:`module` shell function definition for sh-kind shell to
1114 enclose the output generated by :file:`modulecmd.tcl` in quotes in order to
1115 pass it to the eval command. This change fixes definition of shell function,
1116 especially when coming from shell script evaluation over the
1117 :subcmd:`sh-to-mod` and :mfcmd:`source-sh` mechanisms. (fix issue #434)
1118 * Fix csh shell alias detection on :subcmd:`sh-to-mod` and :mfcmd:`source-sh`
1119 mechanisms when enclosed in parenthesis. (fix issue #434)
1120 * Include for fish shell environment analysis on :subcmd:`sh-to-mod` and
1121 :mfcmd:`source-sh` mechanisms the private functions defined by evaluated
1122 script, in order to catch all definitions that may be useful for shell
1123 completion.
1124 * Fix the :subcmd:`sh-to-mod` and :mfcmd:`source-sh` mechanisms to correctly
1125 detect empty function on fish shell.
1126 * Script: add :command:`pre-commit` git hook script to help verify if commits
1127 are free of misspellings (with `codespell`_ tool) and trailing spaces.
1128 * Doc: fix typos found in documentation with Aspell utility.
1129 * Doc: describe :ref:`Dependencies between modulefiles` in
1130 :ref:`modulefile(5)` man page. (fix issues #431 and #433)
1131 * Script: update :command:`pre-commit` git hook script to spell check
1132 documentation files with `Aspell`_ tool.
1133 * Script: add :command:`commit-msg` git hook script to spell check commit
1134 message with `Aspell`_ tool.
1135 * Doc: clarify that ``#%Module`` is a file signature also called Modules magic
1136 cookie.
1137 * Doc: update the :ref:`module ENVIRONMENT` section in :ref:`module(1)` man
1138 page to provide for each Modules environment variable the name of the
1139 configuration option that could be used to set the variable with the
1140 :subcmd:`config` sub-command.
1141 * Doc: clarify in :ref:`module(1)` man page that
1142 :envvar:`MODULES_SET_SHELL_STARTUP`, :envvar:`MODULES_SHELLS_WITH_KSH_FPATH`
1143 and :envvar:`MODULES_WA_277` should be set prior Modules initialization to
1144 get taken into account.
1145 * Doc: update :ref:`INSTALL` document to provide the name of the configuration
1146 option linked the installation options.
1147 * Doc: describe in :ref:`module(1)` man page the default value of each
1148 configuration option and linked installation option and command-line
1149 switches.
1150 * Doc: add *Configuration options* section in :ref:`INSTALL` document with a
1151 table summarizing all configuration options and their relative installation
1152 options and environment variables.
1153 * Add the :mfcmd:`pushenv` modulefile command for compatibility with Lmod Tcl
1154 modulefiles. This command sets designated environment variable with
1155 specified value and save the previous value set to restore it when the
1156 modulefile is unloaded. Previous values are saved in a
1157 :envvar:`__MODULES_PUSHENV_\<VAR\>` environment variable.
1158 * Doc: add :ref:`Compatibility with Lmod Tcl modulefile` section in
1159 :ref:`modulefile(5)` man page.
1160 * Update definition of the ``module()`` python function and python
1161 initialization script to explicitly send output to ``sys.stderr`` to get the
1162 ability to catch this content.
1163 * Lib: handle ``sysconf`` error in function implementing the
1164 ``initStateUsergroups`` procedure. (contribution from Lukáš Zaoral)
1165 * Introduce the :option:`--tag` option for the :subcmd:`load`,
1166 :subcmd:`try-load`, :subcmd:`load-any`, :subcmd:`switch` sub-commands and
1167 associated :mfcmd:`module` modulefile commands and :mfcmd:`prereq`,
1168 :mfcmd:`prereq-all`, :mfcmd:`depends-on` and :mfcmd:`always-load` modulefile
1169 commands. This new option applies specified tags to the module to load.
1170 * Record tags set to loaded modules with the :option:`--tag` option in the
1171 :envvar:`__MODULES_LMEXTRATAG` environment variable to make this information
1172 persists after module being loaded.
1173 * When saving a collection, record loaded module tags set with the
1174 :option:`--tag` option and those resulting from module load states (like
1175 ``auto-loaded`` and ``keep-loaded``). The ``--notuasked`` string previously
1176 used to designate auto-loaded modules in collection is changed into the
1177 ``--tag=auto-loaded`` option.
1178 * Introduce the :mconfig:`collection_pin_tag` configuration option, that
1179 records in collection all tags set on loaded modules when enabled. Option is
1180 disabled by default and when set it defines the :envvar:`MODULES_COLLECTION\
1181 _PIN_TAG` environment variable.
1182 * When a collection is saved, its content starts with a ``#%Module5.1`` file
1183 signature if :option:`--tag` option is recorded in it.
1184 * Update the :subcmd:`restore`, :subcmd:`savelist`, :subcmd:`saveshow` and
1185 :subcmd:`is-saved` sub-commands to exclude from result or return an error
1186 when checking a collection expressing a higher Modules version requirement
1187 in its header signature than the one currently in use.
1188 * Doc: describe :ref:`differences between run-command file and modulefile
1189 interpretation<Modulefile and run-command interp diff>` in
1190 :ref:`modulefile(5)` man page.
1191 * Doc: describe :mfcmd:`module` sub-commands available as modulefile Tcl
1192 command for each interpretation context in :ref:`modulefile(5)` man page.
1193 * When loading a module with some extra tags defined through the
1194 :option:`--tag` option, if this module is already loaded the new tags are
1195 added to those already set.
1196 * When reporting result of :subcmd:`avail` or :subcmd:`list` sub-commands,
1197 enclose module names in single quotes if they contain a space character.
1198 * When mentioning the loading, unloading or refreshing evaluation of a module,
1199 report the tags associated to this module as done when printing results of
1200 :subcmd:`list` sub-command.
1201 * Fix :ref:`log-module-command` cookbook recipe not to break Modules
1202 initialization when using provided :file:`siteconfig.tcl` file. (fix issue
1203 #453 with contribution from Eric Burgueño)
1204 * Mention tagging evaluation of a module, when tag list of an already loaded
1205 module is updated.
1206
1207 .. _Code of conduct: https://github.com/envmodules/modules/blob/main/CODE_OF_CONDUCT.md
1208 .. _codespell: https://github.com/codespell-project/codespell
1209 .. _Aspell: http://aspell.net/
1210
1211
1212 .. _5.0 release notes:
1213
1214 Modules 5.0.1 (2021-10-16)
1215 --------------------------
1216
1217 * Doc: add *How to preserve my loaded environment when running screen* entry
1218 in :ref:`FAQ`.
1219 * Fix the advanced version specifier resolution when the
1220 :mconfig:`extended_default` option is off and :mconfig:`icase` option is on
1221 when resolving version list specification. (fix issue #411)
1222 * Doc: improve the :ref:`log-module-command` cookbook to rely on the ``trace``
1223 Tcl command to track every modulefile evaluation and module/ml procedure
1224 calls. (fix issue #412)
1225 * Doc: fix missing space between list entries in :ref:`variants` design doc.
1226 (fix issue #413)
1227 * Correctly detect tags set on loaded modules when refreshing them.
1228 * Set the :envvar:`__MODULES_AUTOINIT_INPROGRESS` environment variable when
1229 running the :subcmd:`autoinit` sub-command and quit autoinit process if this
1230 variable is found defined and equal to 1 when starting it. Ensure this way
1231 that an autoinit process will not be triggered indefinitely by itself when
1232 the :mconfig:`set_shell_startup` option is enabled and some module loaded at
1233 initialization time relies on the execution of a bash script. (fix issue
1234 #414)
1235 * Remove warning message when unloading a :mfcmd:`prepend-path` or
1236 :mfcmd:`append-path` modulefile command with ``--duplicates`` option set.
1237 (fix issue #421)
1238 * Clarify the module sub-commands that are allowed to be used within a
1239 modulefile. (fix issue #423)
1240 * Install: set in the module magic cookie of the :file:`initrc` configuration
1241 file installed by default the version of Modules required to evaluate this
1242 file.
1243 * Doc: fix documentation of :mfcmd:`getenv` modulefile command to describe
1244 that an empty string is now returned when designated environment variable is
1245 not defined and no default value to return is specified.
1246
1247
1248 Modules 5.0.0 (2021-09-12)
1249 --------------------------
1250
1251 * Remove deprecated :command:`createmodule.sh` and :command:`createmodule.py`
1252 tools as shell script to modulefile conversion is now achieved with the
1253 :subcmd:`sh-to-mod` sub-command.
1254 * Remove mention of the :subcmd:`init*<initadd>` sub-commands in module usage
1255 message to put focus on the collection handling sub-commands.
1256 * Do not declare anymore the ``chdir``, ``module``, ``module-trace``,
1257 ``module-verbosity``, ``module-user`` and ``module-log`` commands under the
1258 modulerc Tcl interpreter as no-op commands. A clear error message is
1259 obtained if these commands are still used in modulerc files instead of
1260 silently ignoring them.
1261 * Return by default an empty string rather ``_UNDEFINED_`` on :mfcmd:`getenv`
1262 modulefile command if passed environment variable is not defined.
1263 * Align empty directory name error message obtained on :subcmd:`use`
1264 sub-command with message obtained when module or collection name is empty.
1265 * Accept non-existent modulepath on :subcmd:`use` sub-command.
1266 * Install: installation option :instopt:`--enable-auto-handling` is set on by
1267 default which enables the automated module handling mode (see
1268 :envvar:`MODULES_AUTO_HANDLING`).
1269 * Install: installation option :instopt:`--enable-extended-default` is set on
1270 by default which allows partial module version specification (see
1271 :envvar:`MODULES_EXTENDED_DEFAULT`).
1272 * Install: installation option :instopt:`--enable-advanced-version-spec` is
1273 set on by default which activates the :ref:`Advanced module version
1274 specifiers`
1275 * Install: installation option :instopt:`--enable-color` is set on by default
1276 which enables the ``auto`` output color mode (see :envvar:`MODULES_COLOR`).
1277 * Install: installation option :instopt:`--with-icase` is set to ``search``
1278 by default to activate case insensitive match on search contexts (see
1279 :envvar:`MODULES_ICASE`).
1280 * Install: installation option :instopt:`--enable-new-features` has been reset
1281 following major version change as all the options it implied are now enabled
1282 by default.
1283 * Install: installation option :instopt:`--enable-set-shell-startup` is set
1284 off by default but could be enabled once installed through the
1285 :file:`initrc` configuration file.
1286 * Install: installation option :instopt:`--with-initconf-in` is set to
1287 ``etcdir`` by default to locate configuration files in the directory
1288 designated by the :instopt:`--etcdir` option. Therefore the initialization
1289 configuration file is named :file:`initrc` in this directory, and the
1290 modulepath-specific configuration file is named :file:`modulespath`.
1291 * Only look at configuration files found in the location designated by the
1292 :instopt:`--etcdir` or :instopt:`--initdir` option (depending on the value
1293 of :instopt:`--with-initconf-in` option). Configuration files were
1294 previously searched in both locations.
1295 * Install: remove installation option ``--enable-compat-version``.
1296 Compatibility version co-installation is discontinued. :command:`switchml`
1297 shell function and :envvar:`MODULES_USE_COMPAT_VERSION` are thus removed as
1298 well.
1299 * Testsuite: introduce the non-regression quick test mode. When the
1300 :envvar:`QUICKTEST` environment variable is set to ``1``, only the main
1301 tests from the non-regression testsuite are run. When first argument of the
1302 :command:`mt` script is ``quick``, tests are run in quick mode.
1303 * Install: run non-regression testsuite in quick mode in RPM spec file.
1304 * Rename the environment variables that are used by Modules to track loaded
1305 environment state (variables whose name starts with ``MODULES_LM``). A
1306 ``__`` prefix is added to the name of these variables to indicate that they
1307 are intended for internal use only.
1308 * Rename the environment variables used to indirectly pass to
1309 :file:`modulecmd.tcl` the value of variables set in quarantine (variables
1310 whose name finishes with ``_modquar``). A
1311 :envvar:`__MODULES_QUAR_<__MODULES_QUAR_\<VAR\>>` prefix is applied to the
1312 name of these variables instead of the ``_modquar`` suffix to indicate they
1313 are intended for Modules internal use of only.
1314 * Update Tcl requirement to version 8.5 as Tcl 8.4 is deprecated since a long
1315 time and this version is not available anymore on recent OS distributions.
1316 Update internal code of :file:`modulecmd.tcl` to take benefit from the
1317 features brought by Tcl 8.5.
1318 * Split source code in several Tcl files hosted in ``tcl`` directory. When
1319 building Modules, the Tcl files are concatenated to make the
1320 :file:`modulecmd.tcl` script.
1321 * Record ``auto-loaded`` tag of loaded modules in :envvar:`__MODULES_LMTAG`
1322 environment variable rather set a specific entry for module in the
1323 ``__MODULES_LMNOTUASKED`` environment variable.
1324 * Rename the environment variables used by the reference counting mechanism
1325 of path-like environment variables. A
1326 :envvar:`__MODULES_SHARE_<__MODULES_SHARE_\<VAR\>>` prefix is applied to the
1327 name of these variables instead of the ``_modshare`` suffix to clearly
1328 indicate they are intended for Modules internal use of only.
1329 * Reference counting mechanism is not anymore applied to the Modules-specific
1330 path variables (like :envvar:`LOADEDMODULES`). As a result no
1331 :envvar:`__MODULES_SHARE_\<VAR\>` variable is set in user environment for
1332 these variables. Exception is made for :envvar:`MODULEPATH` environment
1333 variable where the mechanism still applies.
1334 * When an element is added to a path-like variable through the
1335 :mfcmd:`append-path` or :mfcmd:`prepend-path` modulefile commands, add this
1336 element to the associated reference counter variable (named
1337 :envvar:`__MODULES_SHARE_\<VAR\>`) only when this element is added multiple
1338 times to the path-like variable. When an element is removed from a path-like
1339 variable, this element is removed from the reference counter variable when
1340 its counter is equal to 1.
1341 * When the :subcmd:`use` and :subcmd:`unuse` module sub-commands are not
1342 called during a modulefile evaluation, the reference counter associated with
1343 each entry in :envvar:`MODULEPATH` environment variable is ignored. In such
1344 context, a :subcmd:`module use<use>` will not increase the reference counter
1345 of a path entry already defined and a :subcmd:`module unuse<unuse>` will
1346 remove specified path whatever its reference counter value.
1347 * When the :subcmd:`append-path`, :subcmd:`prepend-path` and
1348 :subcmd:`remove-path` module sub-commands are not called during a modulefile
1349 evaluation, the reference counter associated with each entry in targeted
1350 environment variable is ignored. In such context, a
1351 :subcmd:`module append-path/prepend-path<prepend-path>` will not increase
1352 the reference counter of a path entry already defined and a
1353 :subcmd:`module remove-path<remove-path>` will remove specified path
1354 whatever its reference counter value.
1355 * Fix :subcmd:`unuse` sub-command when several modulepaths are specified as a
1356 single argument (i.e., ``/path/to/dir1:/path/to/dir2``). Enabled modulepaths
1357 were not correctly detected when specified this way.
1358 * Doc: clarify that an already defined path is not added again or moved when
1359 passed to the :subcmd:`use` sub-command or the
1360 :mfcmd:`append-path/prepend-path<prepend-path>` modulefile commands. (fix
1361 issue #60)
1362 * Change the :subcmd:`refresh` sub-command to evaluate all loaded modulefiles
1363 and re-apply the non-persistent environment changes they define (i.e., shell
1364 aliases and functions). With this change the :subcmd:`refresh` sub-command
1365 is restored to the behavior it had on Modules version 3.2.
1366 * Evaluate the modulefile commands resulting from a :mfcmd:`source-sh` command
1367 through the current modulefile Tcl interpreter in order to evaluate them
1368 according to the current modulefile evaluation mode.
1369 * When initializing Modules, refresh the loaded modules in case some user
1370 environment is already configured. This is especially useful when starting a
1371 sub-shell session as it ensures that the loaded environment in parent shell
1372 is correctly inherited, as the :subcmd:`refresh` sub-command re-applies the
1373 non-persistent environment configuration (i.e., shell alias and function
1374 that are not exported to the sub-shell). (fix issue #86)
1375 * Init: add example code in default :file:`initrc`, the initialization script
1376 of Modules, to either restore user's default collection if it exists or load
1377 a predefined module list at the end of the initialization process.
1378 * When initializing Modules, evaluate the :file:`initrc` configuration file in
1379 addition to the the :file:`modulespath` configuration file and not instead
1380 of this file. :file:`initrc` is evaluated after :file:`modulespath` file.
1381 * When the installation option :instopt:`--enable-modulespath` is set, the
1382 list of modulepath to enable by default is now only defined in the
1383 :file:`modulespath` configuration file and not anymore in the :file:`initrc`
1384 configuration file.
1385 * No error is raised when evaluating in ``display`` mode a modulefile without
1386 a value specified for the :mfcmd:`variant` it defines. This change helps to
1387 learn all the variant a modulefile defines. As a result, the unspecified
1388 variant is not instantiated in the :mfvar:`ModuleVariant` array variable.
1389 (fix issue #406)
1390 * When running the :mfcmd:`unsetenv` modulefile command on an unload
1391 evaluation, do not unset designated environment variable if no value to
1392 restore is provided.
1393 * Fix :mfcmd:`unsetenv` to distinguish between being called on a unload
1394 evaluation without a value to restore or with an empty string value to
1395 restore.
1396 * Make :mfcmd:`system` modulefile command available from a modulerc evaluation
1397 context whatever the underlying module evaluation mode.
1398 * Make :mfcmd:`is-used` modulefile command available from a modulerc
1399 evaluation context.
1400 * Remove internal state ``tcl_version_lt85`` as Tcl 8.5+ is now a requirement.
1401 * Forbid use of :subcmd:`module source<source>` command in modulefile or in an
1402 initialization rc file, the ``source`` Tcl command should be used instead.
1403 :subcmd:`source` sub-command should only be called from the command-line.
1404 * Report the modules loading and unloading during the :command:`module`
1405 command initialization (i.e., during the evaluation of the :file:`initrc`
1406 configuration file). These report messages are disabled when the
1407 :mconfig:`verbosity` configuration option is set to ``concise`` or
1408 ``silent``.
1409 * During a module :subcmd:`restore` or :subcmd:`source`, only report the
1410 module load and unload directly triggered by these sub-commands. Load and
1411 unload triggered by other modules are reported through the automated module
1412 handling messages of the main modules.
1413 * Enforce use of the module magic cookie (i.e., ``#%Module``) at the start of
1414 global or user rc files, :file:`initrc` configuration file or any scriptfile
1415 passed for evaluation to the :subcmd:`source` sub-command. These files are
1416 not evaluated and an error is produced if the magic cookie is missing or if
1417 the optional version number placed after the cookie string is higher than
1418 the version of the :file:`modulecmd.tcl` script in use.
1419 * Doc: alphabetically sort installation option in :ref:`INSTALL` document.
1420 * Update the :instopt:`--enable-quarantine-support` installation option to
1421 control a :mconfig:`quarantine_support` configuration option. When this
1422 option is enabled, the :subcmd:`autoinit` sub-command produces the shell
1423 code for the :command:`module` shell function definition with quarantine
1424 mechanism support. When disabled, code is generated without quarantine
1425 support.
1426 * Install: installation option :instopt:`--enable-quarantine-support` is set
1427 off by default.
1428 * Introduce the :envvar:`MODULES_QUARANTINE_SUPPORT` environment variable to
1429 control the :mconfig:`quarantine_support` configuration option once Modules
1430 is installed. To enable the quarantine mechanism,
1431 :envvar:`MODULES_QUARANTINE_SUPPORT` should be set to ``1`` prior Modules
1432 initialization or :mconfig:`quarantine_support` configuration option should
1433 be set to ``1`` in the :file:`initrc` configuration file.
1434 * Quarantine mechanism code in the Modules shell initialization scripts is now
1435 always defined and mechanism always applies if some environment variables
1436 are defined in :envvar:`MODULES_RUN_QUARANTINE`.
1437 * Code in the :file:`modulecmd.tcl` script to restore environment variables
1438 put in quarantine is now always generated and applies if the
1439 :envvar:`__MODULES_QUARANTINE_SET` environment variable is set to ``1``.
1440 This variable is set by the Modules initialization script prior calling the
1441 :subcmd:`autoinit` sub-command or by the :command:`module` shell function if
1442 it has been generated with quarantine support enabled.
1443 * Install: installation option :instopt:`--enable-silent-shell-debug-support`
1444 is set off by default.
1445 * Code to silence shell debug properties in the Modules shell initialization
1446 scripts is now always defined and mechanism applies if
1447 :envvar:`MODULES_SILENT_SHELL_DEBUG` environment variable is set to ``1``.
1448 * Code to silence shell debug properties in the :command:`module` shell
1449 function could now be enabled if :envvar:`MODULES_SILENT_SHELL_DEBUG` is set
1450 to ``1`` prior Modules initialization or if the
1451 :mconfig:`silent_shell_debug` configuration option is set to ``1`` in the
1452 :file:`initrc` configuration file.
1453 * Doc: clarify TOC and title of :ref:`MIGRATING<MIGRATING>` document.
1454 * Doc: extend description of Modules configuration steps of in :ref:`INSTALL`
1455 document.
1456 * Doc: document :file:`initrc` and :file:`modulespath` configuration files in
1457 :ref:`module(1)` man page.
1458 * Install: replace :file:`example.txt` by :file:`INSTALL.txt` guide in RPM.
1459 * Doc/Install: rename ``diff_v3_v4`` document into :ref:`changes<changes>`.
1460 * Doc: reorganize :ref:`changes` document to let room to describe Modules 5
1461 changes.
1462
1463
1464 .. _4.8 release notes:
1465
1466 Modules 4.8.0 (2021-07-14)
1467 --------------------------
1468
1469 * Introduce the :subcmd:`edit` sub-command that opens modulefile passed as
1470 argument in a text editor. Modulefile can be specified like with any other
1471 sub-command, leveraging defined symbolic versions, aliases or using advanced
1472 version specifiers.
1473 * Add the :mconfig:`editor` configuration option to select the text editor to
1474 use with :subcmd:`edit` sub-command. When this option is set through the
1475 :subcmd:`config` sub-command, the :envvar:`MODULES_EDITOR` environment
1476 variable is set. The :instopt:`--with-editor` installation option controls
1477 the default value of :mconfig:`editor` configuration option. If not set at
1478 installation time, ``vi`` is set as default editor.
1479 * Default value of :mconfig:`editor` configuration option is overridden by the
1480 :envvar:`VISUAL` or the :envvar:`EDITOR` environment variables, which are
1481 both in turn overridden by the :envvar:`MODULES_EDITOR` environment
1482 variable.
1483 * Doc: fix :file:`modulecmd.tcl` internal state check in recipes example
1484 codes. (fix issue #396)
1485 * The :ref:`Advanced module version specifiers` mechanism now allows the use
1486 of version range in version list (for instance ``mod@:1.2,1.4:1.6,1.8:``).
1487 Such specification helps to exclude specific versions. (fix issue #397)
1488 * Install: fix installation scripts to allow building Modules when its
1489 repository is set as a git submodule. (fix issue #398)
1490 * Doc: demonstrate in the :ref:`source-script-in-modulefile` recipe how to use
1491 the :mfcmd:`source-sh` command when software provide a specific
1492 initialization script for each shell it supports. (fix issue #399)
1493 * When defining a shell function with the :mfcmd:`set-function` modulefile
1494 command, only export this function when using the Bash shell (using the
1495 ``export -f`` shell command) to make it available in sub-shell contexts.
1496 Shell function export is not supported on other kind of sh shell (sh, ksh
1497 and zsh). (fix issue #401)
1498 * Doc: add :ref:`variants` design notes.
1499 * Add the :mfcmd:`variant` modulefile command that enables to pass down
1500 arguments, specified when designating the module to evaluate, within
1501 modulefile evaluation context. This command defines a variant name and a
1502 list of allowed values. When evaluated, :mfcmd:`variant` instantiates an
1503 element in the :mfvar:`ModuleVariant` array whose name equals variant name
1504 and value is set with value specified for variant when module is designated.
1505 If specified value does not correspond to an allowed value or if no value
1506 is specified for variant an error is raised.
1507 * Enhance the :ref:`Advanced module version specifiers` to handle variant
1508 specification following `Spack`_'s syntax (e.g., *name=value*). When the
1509 :mconfig:`advanced_version_spec` configuration is enabled, variant could be
1510 specified anywhere a module can be specified.
1511 * Add the ``--default`` option to the :mfcmd:`variant` modulefile command to
1512 indicate the default value of the variant to apply when the designation of
1513 the evaluating module does not mention this variant.
1514 * Add the ``--boolean`` option to the :mfcmd:`variant` modulefile command to
1515 indicate that the variant defined is of the Boolean type, thus no list of
1516 accepted value is expected.
1517 * Enhance the :ref:`Advanced module version specifiers` to handle Boolean
1518 variant specification following `Spack`_'s syntax (e.g., *+name*, *~name*
1519 and *-name*). The *-name* syntax is not supported on :ref:`ml(1)` command as
1520 the minus sign already means to unload designated module.
1521 * Accept any minus argument (*-word*) set after the sub-command name when the
1522 :mconfig:`advanced_version_spec` configuration is enabled and if sub-command
1523 accepts :ref:`Advanced module version specifiers` (like :subcmd:`load` or
1524 :subcmd:`unload` sub-commands). A *false* value may be set to Boolean
1525 variant this way.
1526 * Add the :mconfig:`variant_shortcut` configuration option to define shortcut
1527 characters that could be used to specify and report module variants. Default
1528 value for this option could be set at installation time with the
1529 :instopt:`--with-variant-shortcut` option. No variant shortcut is defined by
1530 default. This value could be superseded by setting up the
1531 :mconfig:`variant_shortcut` option with :subcmd:`config` sub-command. Which
1532 sets the :envvar:`MODULES_VARIANT_SHORTCUT` environment variable.
1533 * Enhance the :ref:`Advanced module version specifiers` to handle variant
1534 shortcut specification (e.g., *<shortcut>value*).
1535 * Record in user loaded environment, with
1536 :envvar:`MODULES_LMVARIANT<__MODULES_LMVARIANT>` environment variable, the
1537 value specified for the variants defined in the loaded modulefiles and their
1538 properties (if it is a Boolean variant and if the value set is the default
1539 one).
1540 * Add the ``variant`` element in the allowed value list of the
1541 :mconfig:`list_output` and :mconfig:`list_terse_output` configuration
1542 options. Set this new element in the default value list of the
1543 :mconfig:`list_output` option. When set, the variant defined for loaded
1544 modules are reported on module :subcmd:`list` command output.
1545 * Add the ``va`` color key in default light and dark color palettes to
1546 graphically enhance the report of variant value.
1547 * Update the key section to explain on :subcmd:`list` sub-command output the
1548 reported variant elements (*name=value*, *+name*, *-name* or
1549 *<shortcut>value*)
1550 * Record variant specification of loaded modules when saving collections and
1551 reload specified variants when restoring these collections.
1552 * When :mconfig:`collection_pin_version` configuration is disabled, only
1553 record in collections the variants whose value is not the default one.
1554 * Update module designation in error, warning or informational messages to
1555 report variant specification enclosed in curly braces (*{}*), enclose module
1556 name and version or variant specification in single quotes (*''*) if they
1557 contain a space character and highlight the module designation in report
1558 message if configured.
1559 * Introduce the :mfcmd:`getvariant` modulefile command to query for currently
1560 evaluating module the value of a given variant name.
1561 * When translating the ``@loaded`` version specifier also retrieve the variant
1562 specified for corresponding loaded module.
1563 * Update hide, forbid and tag mechanisms to apply them only if they match
1564 selected module variant.
1565 * Any variant defined in module specification passed as argument to search
1566 sub-commands (:subcmd:`avail`, :subcmd:`whatis`, :subcmd:`is-avail`,
1567 :subcmd:`path` and :subcmd:`paths`) is ignored.
1568 * Raise an error if a variant named ``version`` is declared in a modulefile to
1569 let room for the future implementation of this specific variant.
1570 * Doc: describe in the :ref:`changes` document argument handling change on
1571 :mfcmd:`setenv` since v3.2. (fix issue #402)
1572 * Introduce the :subcmd:`try-load` sub-command which like :subcmd:`load`
1573 sub-command tries to load the modulefile passed as argument, but does not
1574 complain if this modulefile cannot be found. (fix issue #392)
1575 * Init: fix stderr redirection in fish shell initialization script, now that
1576 use of the ``^`` character to redirect stderr is disabled by default (fish
1577 >=3.3).
1578 * Protect quarantine mechanism code from ``rcexpandparam`` Zsh option when
1579 initializing the :command:`module` command on this shell. (fix issue #403)
1580
1581
1582 .. _4.7 release notes:
1583
1584 Modules 4.7.1 (2021-04-06)
1585 --------------------------
1586
1587 * Doc: clarify the license terms used by the project. (fix issue #389)
1588 * Align all files from the Modules project under the GPLv2+ license. Scripts
1589 and libraries that were previously licensed with GPLv3+ have been moved to
1590 GPLv2+ with the consent of their respective copyright holders. (fix issue
1591 #389)
1592 * Revert "Install: have :file:`configure` script assume the ``.`` dot
1593 directory when invoked without the prepended ``./``" as consent was not
1594 obtained from author to re-license the contribution to GPLv2+.
1595 * Doc: fixes few typos in :ref:`module(1)` and :ref:`modulefile(5)`.
1596 * Update the :subcmd:`sh-to-mod` mechanism to support version 3.2 of the fish
1597 shell. Fish 3.2 introduces the ``.`` builtin command that should be
1598 regexp-escaped when determining the shell functions or aliases defined by
1599 the script analyzed by :subcmd:`sh-to-mod`.
1600 * Vim: update addon files to highlight modulefile variables
1601 :mfvar:`ModuleTool`, :mfvar:`ModuleToolVersion` and
1602 :mfvar:`ModulesCurrentModulefile`.
1603 * Doc: update the description and default value of the
1604 :instopt:`--with-dark-background-colors` and
1605 :instopt:`--with-light-background-colors` installation options.
1606 * Doc: add description of changes that occurred on versions 4.6 and 4.7 for
1607 the :instopt:`--with-dark-background-colors` and
1608 :instopt:`--with-light-background-colors` installation options and for the
1609 :envvar:`MODULES_COLORS` environment variable.
1610 * Doc: correct the default value of the :instopt:`--with-tag-abbrev`
1611 installation option.
1612 * Doc: add :ref:`sticky-modules-rcp` cookbook recipe.
1613
1614
1615 Modules 4.7.0 (2021-02-19)
1616 --------------------------
1617
1618 * Doc: simplify TOC of :ref:`MIGRATING` document
1619 * Add the :mfvar:`ModuleTool` and :mfvar:`ModuleToolVersion` Modules
1620 variables to determine during modulefile or modulerc evaluation the name and
1621 version of the *module* implementation currently in use.
1622 * Introduce the :mfcmd:`versioncmp` modulefile command to compare two version
1623 strings passed as argument.
1624 * Enable the use of wildcard character to designate multiple directories at
1625 once in :file:`modulespath` configuration file. (fix issue #125)
1626 * Distinguish aliases from symbolic versions in
1627 :envvar:`MODULES_LMALTNAME<__MODULES_LMALTNAME>` environment variable.
1628 Prefix these alias entries with the ``al|`` string.
1629 * Fetch modulefile modification time only if required by :subcmd:`list`
1630 sub-command display format.
1631 * Use symbolic versions recorded in environment, with
1632 :envvar:`MODULES_LMALTNAME<__MODULES_LMALTNAME>` variable, to report the
1633 symbols applying to loaded modules on :subcmd:`list` sub-command. Modulerc
1634 files are not evaluated anymore when performing a module list.
1635 * Move the definition of the :envvar:`FPATH` environment variable for Modules
1636 initialization on ksh shell from the initialization script of this shell to
1637 the resulting output of the :subcmd:`autoinit` sub-command.
1638 * Introduce the :mconfig:`shells_with_ksh_fpath` configuration option to
1639 define a list of shell where to ensure that any ksh sub-shell will get the
1640 module function defined by use of the :envvar:`FPATH` environment variable.
1641 When the :mconfig:`shells_with_ksh_fpath` option is set through the
1642 :subcmd:`config` sub-command, the :envvar:`MODULES_SHELLS_WITH_KSH_FPATH`
1643 environment variable is set. Accepted values are a list of shell among *sh*,
1644 *bash*, *csh*, *tcsh* and *fish* separated by colon character (``:``).
1645 * Add the :mconfig:`implicit_requirement` configuration option to control
1646 whether a prereq or a conflict requirement should be implicitly set onto
1647 modules respectively specified on :mfcmd:`module load<module>` or
1648 :mfcmd:`module unload<module>` commands in modulefile. Default value for
1649 this option could be set at configure time with the
1650 :instopt:`--enable-implicit-requirement` option (enabled by default). This
1651 value could be superseded by setting up the :mconfig:`implicit_requirement`
1652 option with :subcmd:`config` sub-command. Which sets the
1653 :envvar:`MODULES_IMPLICIT_REQUIREMENT` environment variable. (fix issue
1654 #260)
1655 * Add the ``--not-req`` option to the :mfcmd:`module` modulefile command to
1656 inhibit for its ``load`` and ``unload`` sub-commands the definition of a
1657 prereq or conflict requirement onto specified modules.
1658 * Add the ``lpopState`` and ``currentState`` procedures to respectively remove
1659 or return the last entry from the list of values of a given state.
1660 * Add the ``topState`` and ``depthState`` procedures to respectively return
1661 the first element from or the number of elements in the list of values of a
1662 given state.
1663 * Remove the pre-definition of runtime states with no specific property. These
1664 basic states are defined on-the-fly which implied they are not reported on a
1665 :subcmd:`module config --dump-state<config>` command unless if instantiated.
1666 * Introduce the ``loaded`` symbolic version among advanced version specifiers
1667 (e.g. ``foo@loaded``) to designate the currently loaded version of specified
1668 module. (fix issue #366)
1669 * Doc: add *Module tags* design notes.
1670 * Report tags applying to the modules returned by the :subcmd:`avail`
1671 sub-command. Adapt the regular, terse and JSON output styles to report these
1672 tags along the module they are attached to (enclosed in ``<>``). Reported
1673 tags currently are states that apply to modules: ``auto-loaded``,
1674 ``forbidden``, ``hidden``, ``loaded``, ``nearly-forbidden``, ``sticky`` and
1675 ``super-sticky``.
1676 * Record tags applying to each loaded module in the
1677 :envvar:`MODULES_LMTAG<__MODULES_LMTAG>` environment variable to make this
1678 information persist after module being loaded.
1679 * Report tags applying to the loaded modules returned by the :subcmd:`list`
1680 sub-command. Adapt the regular and JSON output styles to report these tags
1681 along the module they are attached to (enclosed in ``<>``). Reported tags
1682 currently are states applying to loaded modules: ``auto-loaded``,
1683 ``hidden-loaded``, ``nearly-forbidden``, ``sticky`` and ``super-sticky``.
1684 * Introduce the :mfcmd:`module-info tags<module-info>` modulefile command to
1685 query the tags that apply to the currently evaluated modulefile.
1686 * Add the :mfcmd:`module-tag` modulefile command to associate tag to
1687 designated modulefile. Those tags are reported on :subcmd:`avail` and
1688 :subcmd:`list` sub-commands along the module they are attached to.
1689 :mfcmd:`module-tag` supports the advanced module version specifier syntax.
1690 * Add the :mconfig:`tag_abbrev` configuration option to define abbreviated
1691 strings for module tags and use these abbreviations instead of tag names
1692 when reporting tags on :subcmd:`avail` and :subcmd:`list` command results.
1693 Default value for this option could be set at configure time with the
1694 :instopt:`--with-tag-abbrev` option. By default the following abbreviations
1695 are set: ``aL`` for *auto-loaded*, ``F`` for *forbidden*, ``H`` for
1696 *hidden*, ``H`` for *hidden-loaded*, ``L`` for *loaded*, ``nF`` for
1697 *nearly-forbidden*, ``S`` for *sticky*, ``sS`` for *super-sticky*. This
1698 value could be superseded by setting up the :mconfig:`tag_abbrev` option
1699 with :subcmd:`config` sub-command. Which sets the
1700 :envvar:`MODULES_TAG_ABBREV` environment variable.
1701 * A Select Graphic Rendition (SGR) code can be associated to module tag names
1702 or abbreviation strings in the color palette to graphically render these
1703 tags over the module name they are associated to. The default light and dark
1704 color palettes have been updated to set a color code for all basic module
1705 tags. When a color code is set for a tag, it is then graphically rendered
1706 over the module names and not reported along module name by its tag name or
1707 abbreviation. When multiple colored tags apply to a given module, each tag
1708 is graphically rendered over a sub-part of the module name.
1709 * Add the :mconfig:`tag_color_name` configuration option to designate module
1710 tags whose graphical rendering should be applied to their own name or
1711 abbreviation rather than over the module name they are attached to.
1712 Default value for this option could be set at configure time with the
1713 :instopt:`--with-tag-color-name` option (empty by default). This value could
1714 be superseded by setting up the :mconfig:`tag_color_name` option with
1715 :subcmd:`config` sub-command. Which sets the
1716 :envvar:`MODULES_TAG_COLOR_NAME` environment variable.
1717 * Add the ``--hidden-loaded`` option to the :mfcmd:`module-hide` modulefile
1718 command that indicates module should be hidden once loaded. When set, the
1719 ``hidden-loaded`` module tag applies to module specification set on
1720 :mfcmd:`module-hide` command.
1721 * Do not report on :subcmd:`list` sub-command results the loaded modules
1722 associated with the ``hidden-loaded`` tag, unless if the :option:`--all`
1723 option is set.
1724 * Doc: add an ``hidden-loaded`` example in the *Hide and forbid modules*
1725 cookbook recipe.
1726 * Introduce the ``verbose2`` verbosity level between ``verbose`` and ``trace``
1727 levels. Verbose2 mode can be enabled by setting the :mconfig:`verbosity`
1728 config to the ``verbose2`` value or by using the :option:`-v` command-line
1729 switch twice.
1730 * Do not report the load, unload or switch of modules set ``hidden-loaded`` if
1731 these modules have been loaded, unloaded or switched automatically. Unless
1732 the verbosity mode is set to ``verbose2`` or any higher level or if any
1733 specific messages have to be reported for these module evaluations.
1734 * Report when trying to load a module which is already loaded or when trying
1735 to unload a module which is not loaded in case the verbosity mode is set to
1736 ``verbose2`` or any higher level. (fix issue #187)
1737 * Doc: improve readability of version 4 improvements in :ref:`changes`
1738 document.
1739 * Introduce stickiness: module tagged ``sticky`` with :mfcmd:`module-tag`
1740 command cannot be unloaded unless if the unload is forced or if the module
1741 is reloaded. (fix issue #269)
1742 * Introduce super-stickiness: module tagged ``super-sticky`` with
1743 :mfcmd:`module-tag` command cannot be unloaded even if the unload is forced
1744 unless if the module is reloaded. (fix issue #269)
1745 * Allow swap of sticky or super-sticky modules by another modulefile version
1746 if stickiness definition applies to module parent name. E.g., *foo/1.0* can
1747 be swapped by *foo/2.0* if sticky tag applies to *foo*.
1748 * When forcing purge with a :subcmd:`purge --force<purge>` sub-command, also
1749 unload the modules that are depended by non-unloadable modules.
1750 * Doc: improve readability of Modules installation configuration in
1751 :ref:`INSTALL` document and enable hypertext reference to these elements.
1752 * Doc: improve readability of module command configuration option in
1753 :ref:`module(1)` document and enable hypertext reference to these elements.
1754 * Doc: describe in HTML documentation when installation options, module
1755 command configuration options and options of modulefile command or module
1756 sub-command were introduced.
1757 * Doc: update HTML documentation Table Of Content.
1758 * Doc: improve markup of module sub-commands, modulefile commands,
1759 installation option, module configuration option across documentation.
1760 * Doc: colorize terminal output examples in :ref:`MIGRATING` document.
1761 * Abort modulefile read if first file content chunk does not start with the
1762 ``#%Module`` magic cookie. (fix issue #375)
1763 * Install: add installation option :instopt:`--enable-new-features` that
1764 enables all at once the installation options that are disabled by default
1765 due to the substantial behavior changes they imply.
1766 * Add a *Key* section at the end of :subcmd:`avail` and :subcmd:`list`
1767 sub-commands to explain the meaning of graphical renditions or of elements
1768 set in parentheses or chevrons along module name.
1769 * Fix output of :subcmd:`avail` and :subcmd:`list` sub-commands on very small
1770 terminal width. (fix issue #378)
1771 * Add :mconfig:`mcookie_version_check` configuration to define if version set
1772 in modulefile magic cookie should be checked against :command:`module`
1773 current version to determine if modulefile can be evaluated. The new
1774 configuration, which is enabled by default, can be set at installation time
1775 with configure option :instopt:`--enable-mcookie-version-check` or can be
1776 superseded later on with the :envvar:`MODULES_MCOOKIE_VERSION_CHECK`
1777 environment variable. (fix issue #377)
1778 * Fix output of modulefile evaluation error stack trace on very small terminal
1779 width. (fix issues #379 and #381)
1780 * Correct :subcmd:`config` sub-command to set :mconfig:`nearly_forbidden_days`
1781 configuration. (fix issue #380)
1782 * Init: reduce usage of helper variables in :file:`bash_completion` and
1783 :file:`tcsh_completion` that are showing up in the output of the shell's
1784 ``set`` command. (fix issue #382 with contribution from Colin Marquardt)
1785 * Consider modulepath starting with a reference to an environment variable as
1786 absolute. (fix issue #376)
1787 * Consider the :subcmd:`module load<load>` performed in the user or the global
1788 RC file like load commands issued from initialization RC file. (fix issue
1789 #372)
1790 * Install: have :file:`configure` script assume the ``.`` dot directory when
1791 invoked without the prepended ``./``. (contribution from R.K. Owen)
1792 * Install: disable the Makefile rules to build the HTML documentation in case
1793 if the documentation is found pre-built in the dist archive.
1794 * Install: do not flag documentation as pre-built if :file:`configure` script
1795 is ran another time after building docs.
1796 * Restrict the value accepted by :mconfig:`nearly_forbidden_days`
1797 configuration and :instopt:`--with-nearly-forbidden-days` installation
1798 option to integers comprised between 0 and 365.
1799 * Install: color *ERROR* and *WARNING* message headers produced by
1800 :file:`configure` script if output is sent to a terminal.
1801 * Install: split error messages produced by :file:`configure` script over an
1802 additional line when too long.
1803 * Doc: add *Output configuration* design notes.
1804 * Introduce the :mconfig:`avail_output` and :mconfig:`avail_terse_output`
1805 configuration options to define the content to report in addition to the
1806 available module names respectively for :subcmd:`avail` sub-command regular
1807 and terse output modes. Excepted value for these configuration options is a
1808 colon separated list of elements to report. Default value is
1809 ``modulepath:alias:dirwsym:sym:tag:key`` for :mconfig:`avail_output` and
1810 ``modulepath:alias:dirwsym:sym:tag`` for :mconfig:`avail_terse_output`.
1811 These values can be changed at installation time respectively with the
1812 :instopt:`--with-avail-output` and :instopt:`--with-avail-terse-output`
1813 options. These values can then be superseded by using the :subcmd:`config`
1814 sub-command which sets the :envvar:`MODULES_AVAIL_OUTPUT` and
1815 :envvar:`MODULES_AVAIL_TERSE_OUTPUT` environment variables.
1816 * Introduce the :mconfig:`list_output` and :mconfig:`list_terse_output`
1817 configuration options to define the content to report in addition to the
1818 available module names respectively for :subcmd:`list` sub-command regular
1819 and terse output modes. Excepted value for these configuration options is a
1820 colon separated list of elements to report. Default value is
1821 ``header:idx:sym:tag:key`` for :mconfig:`list_output` and ``header`` for
1822 :mconfig:`list_terse_output`. These values can be changed at installation
1823 time respectively with the :instopt:`--with-list-output` and
1824 :instopt:`--with-list-terse-output` options. These values can then be
1825 superseded by using the :subcmd:`config` sub-command which sets the
1826 :envvar:`MODULES_LIST_OUTPUT` and :envvar:`MODULES_LIST_TERSE_OUTPUT`
1827 environment variables.
1828 * Add the :option:`--output`/:option:`-o` command-line switches to supersede
1829 the output configuration of :subcmd:`avail` or :subcmd:`list` sub-commands
1830 on their regular or terse output modes.
1831 * Remove the ``avail_report_dir_sym`` and ``avail_report_mfile_sym`` locked
1832 configuration options whose behaviors can now be obtained by respectively
1833 adding the ``dirwsym`` and ``sym`` elements to the :mconfig:`avail_output`
1834 or :mconfig:`avail_terse_output` configuration options.
1835 * When ``modulepath`` is omitted from the content to report on :subcmd:`avail`
1836 sub-command, available modules collected from global/user rc and enabled
1837 modulepaths are aggregated and reported all together.
1838 * Install: print generated file names rather commands executed to generate
1839 these files on Makefile build targets. Output obtained when building Modules
1840 is this way simplified. When option ``V=1`` is passed to ``make``, the
1841 verbose mode is enabled and run commands are shown. The simplified ``make``
1842 output does not apply to the install, test and clean targets or any target
1843 similar to them.
1844 * Install: fix configure and build files of Modules Tcl extension library to
1845 make them compatible with autoconf >=2.69.
1846 * Script: correctly detect previous Modules version number released from a
1847 side git branch on :command:`mpub` command.
1848 * Install: align RPM spec file syntax with spec file used on Fedora. Add
1849 missing build dependency on ``make`` package. Also remove obsolete ``Group``
1850 RPM tag.
1851 * Add the :mconfig:`term_width` configuration option to set the width of the
1852 output. This configuration option is set to ``0`` by default, which means
1853 that the output width is the full terminal width. The
1854 :option:`--width`/:option:`-w` command line switches are added to supersede
1855 the value of the configuration option. (fix issue #359 with contribution
1856 from Anaïs Gaertner)
1857 * Doc: add a *Get Modules* section in :ref:`INSTALL` document to provide
1858 download links for Modules' sources. (fix issue #387)
1859
1860
1861 .. _4.6 release notes:
1862
1863 Modules 4.6.1 (2020-11-14)
1864 --------------------------
1865
1866 * Lib: implement ``initStateClockSeconds`` as a Tcl command in
1867 libtclenvmodules to provide an optimized way to retrieve current Epoch time.
1868 * Lib: implement ``parseDateTimeArg`` as a Tcl command in libtclenvmodules to
1869 provide an optimized way to convert a datetime string into an Epoch time.
1870 * When full module specification is equal to ``@``, raise an error as no
1871 module name is provided. (fix issue #362)
1872 * Optimize internal recording of hidden module and tag specification when
1873 parsing modulerc files in order to reduce the time taken to test if a given
1874 module is hidden or if a given tag applies to it.
1875 * Script: add the ability to select the benchmark test to perform on
1876 :command:`mb` utility.
1877 * Doc: add *Use new features without breaking old module command* cookbook
1878 recipe
1879 * Doc: rework option description for :mfcmd:`module-hide` and
1880 :mfcmd:`module-forbid` commands in :ref:`modulefile(5)` document.
1881 * Doc: describe in :ref:`changes` document that shell special characters like
1882 backticks are escaped when used in values starting Modules 4.0. (fix issue
1883 #365)
1884 * Doc: make the ENVIRONMENT section from :ref:`modulefile(5)` man page point
1885 to the ENVIRONMENT section of :ref:`module(1)` man page.
1886 * Fix :subcmd:`clear` sub-command to unset the
1887 :envvar:`MODULES_LMSOURCESH<__MODULES_LMSOURCESH>` environment variable.
1888 (fix issue #367)
1889 * Correctly return on :subcmd:`avail` sub-command a symbolic version defined
1890 in a global RC file when specifically searched. (fix issue #368)
1891 * Fix module hiding resolution for symbolic versions defined in a global RC
1892 file when :mfcmd:`module-hide` statements are set in the modulepath where
1893 the modulefiles targeted by these symbols are located. (fix issue #369)
1894 * When a module fails to unload during a :subcmd:`purge` sub-command, preserve
1895 loaded the modules it requires to keep environment consistent. (fix issue
1896 #370)
1897 * Doc: add *Hide and forbid modules* cookbook recipe.
1898
1899
1900 Modules 4.6.0 (2020-09-16)
1901 --------------------------
1902
1903 * Rework internal state handling to gather all state definitions in a global
1904 array and use the same initialization and retrieval procedure, named
1905 ``getState``, for all these states.
1906 * Add the ``setState``, ``unsetState``, ``lappendState``, ``isStateDefined``
1907 and ``isStateEqual`` procedures to provide unified ways to set or check the
1908 value of state.
1909 * Introduce the :subcmd:`sh-to-mod` sub-command, to evaluate shell script and
1910 determine the environment changes it does. Corresponding modulefile
1911 content is outputted as a result. Changes on environment variables, shell
1912 aliases, shell functions and current working directory are tracked. The
1913 following shells are supported: sh, dash, csh, tcsh, bash, ksh, ksh93, zsh
1914 and fish.
1915 * Doc: add *Source shell script in modulefile* design notes.
1916 * Introduce the :mfcmd:`source-sh` modulefile command, to evaluate shell
1917 script and apply resulting environment changes through modulefile commands.
1918 When a modulefile using :mfcmd:`source-sh` modulefile command is loaded, the
1919 modulefile commands resulting from shell script evaluation are recorded in
1920 the :envvar:`MODULES_LMSOURCESH<__MODULES_LMSOURCESH>` environment variable
1921 to be able to undo these environment changes when modulefile is unloaded and
1922 to report the modulefile commands used when modulefile is displayed. The
1923 same kind of environment changes than the :subcmd:`sh-to-mod` sub-command
1924 are tracked. The same list of shells than :subcmd:`sh-to-mod` sub-command
1925 are supported. (fix issue #346)
1926 * Doc: add *Source shell script in modulefile* cookbook recipe.
1927 * Doc: embed new Modules logo on website, online README and documentation
1928 portal.
1929 * Install: disable by default the build of Modules compatibility version. From
1930 now on, option :instopt:`--enable-compat-version` has to be set to trigger
1931 this build.
1932 * Introduce the ``username`` sub-command to the :mfcmd:`module-info`
1933 modulefile command to get the username of the user currently running
1934 :file:`modulecmd.tcl` or to test a string passed as argument corresponds to
1935 this username.
1936 * Introduce the ``usergroups`` sub-command to the :mfcmd:`module-info`
1937 modulefile command to get all the groups of the user currently running
1938 :file:`modulecmd.tcl` or to test a string passed as argument corresponds to
1939 one of these groups.
1940 * Doc: improve markup of :ref:`NEWS` and :ref:`MIGRATING` documents starting
1941 from this 4.6 version to enable references to module sub-commands, command
1942 line switches, environment variables and modulefile Tcl commands.
1943 * Use inclusive terminology to eliminate *master* and *slave* terms as much as
1944 possible from code source and documentation.
1945 * Doc: use a versioned magic cookie in examples that demonstrate new
1946 modulefile features. (fix issue #349)
1947 * Introduce the :instopt:`--enable-multilib-support` configure option to add
1948 mechanism in :file:`modulecmd.tcl` to look at an alternative location to
1949 find the Modules Tcl extension library in case this library cannot be found
1950 at its main location.
1951 * Lib: remove *fetch_hidden* argument from ``getFilesInDirectory`` procedure
1952 of Modules Tcl extension library.
1953 * Doc: add *Hide or forbid modulefile* design notes.
1954 * Add the :mfcmd:`module-hide` modulefile command, to dynamically hide
1955 modulefile, module alias or symbolic version matching passed specification.
1956 When hidden, a modulefile, an alias or a symbolic version is not reported
1957 nor selected unless referred by its exact name, like for module whose name
1958 or version starts with a dot character. :mfcmd:`module-hide` supports the
1959 advanced module version specifiers. (fix issue #202)
1960 * Add option ``--soft`` to the :mfcmd:`module-hide` modulefile command to
1961 introduce a soften level of camouflage: modules targeted by such hide
1962 directive are made visible as soon as their root name is part of search
1963 query.
1964 * Add option ``--hard`` to the :mfcmd:`module-hide` modulefile command to
1965 introduce a hardened level of camouflage: modules targeted by such hide
1966 directive keep being hidden even if they are fully matched by search query.
1967 * Do not report among :subcmd:`whatis` search result the modulefiles with
1968 version name prefixed by a dot character and targeted by a symbolic version
1969 unless if they are precisely searched.
1970 * When a loading module has hidden alternative names (hidden due to their
1971 name or version starting with a dot character or because they match a
1972 :mfcmd:`module-hide` statement), these alternative names are not recorded in
1973 environment unless if they are not hard-hidden and if they have been used in
1974 query to select loading module.
1975 * On :subcmd:`avail` sub-command, remove hidden symbolic versions from the
1976 list to display along modulefile or directory they target, unless these
1977 symbols are not hard-hidden and are used in query to search modules.
1978 * When the :option:`--default` filter of :subcmd:`avail` sub-command is set,
1979 unhide all the *default* symbolic versions or modules targeted by these
1980 symbols unless if they are hard-hidden.
1981 * Define the *default* and *latest* automatic symbolic versions only if
1982 relative module name matches search query to ensure all elements for this
1983 module have been processed prior assigning the symbols.
1984 * In case a symbolic version is transitively applied toward a modulefile, like
1985 for instance when this symbol is first set onto a directory, record the
1986 resolution of each transitively applied symbol. By doing so, a module
1987 :subcmd:`load` tentative using the transitively applied symbolic version
1988 will now correctly resolve to the modulefile targeted by symbol.
1989 * Fix use of the advanced version specifiers in arguments to the
1990 :mfcmd:`is-avail` modulefile command.
1991 * Introduce the :option:`--all`/:option:`-a` option for :subcmd:`avail`,
1992 :subcmd:`aliases`, :subcmd:`whatis` and :subcmd:`search` sub-commands, to
1993 include in the search process all hidden modulefiles, module aliases or
1994 symbolic versions. Hard-hidden modules stay hidden even if
1995 :option:`--all`/:option:`-a` option is used.
1996 * Add the :mfcmd:`module-forbid` modulefile command, to dynamically forbid
1997 evaluation of modulefile matching passed specification. When forbidden, a
1998 module cannot be loaded and an access error is obtained when trying to
1999 evaluate them. :mfcmd:`module-forbid` supports the advanced module version
2000 specifiers.
2001 * Add ``--not-user`` and ``--not-group`` options to :mfcmd:`module-hide` and
2002 :mfcmd:`module-forbid` modulefile commands to ignore hiding or forbidding
2003 definition if current user is respectively part of specified username list
2004 or member of one of specified group list.
2005 * Add ``--before`` and ``--after`` options to :mfcmd:`module-hide` and
2006 :mfcmd:`module-forbid` modulefile commands to ignore hiding or forbidding
2007 definition respectively after and before a specified date time. Accepted
2008 date time format is ``YYYY-MM-DD[THH:MM]``.
2009 * Add ``--message`` option to :mfcmd:`module-forbid` modulefile command to
2010 supplement the error message obtained when trying to evaluate a forbidden
2011 module.
2012 * When a module that will soon be forbidden (as the date limit specified on
2013 the ``--after`` option of a matching :mfcmd:`module-forbid` command is near)
2014 is evaluated, warn user this module access will soon be denied.
2015 * The range of time the above warning appears can be controlled with the
2016 :mconfig:`nearly_forbidden_days` configuration option, whose value equals to
2017 the number of days prior the module starts to be forbidden. This
2018 configuration is set to ``14`` (days) by default and this value can be
2019 controlled at :file:`configure` time with
2020 :instopt:`--with-nearly-forbidden-days` option. When the
2021 :mconfig:`nearly_forbidden_days` configuration is set through the
2022 :subcmd:`config` sub-command, the :envvar:`MODULES_NEARLY_FORBIDDEN_DAYS`
2023 environment variable is set.
2024 * Add ``--nearly-message`` option to :mfcmd:`module-forbid` modulefile command
2025 to supplement the warning message obtained when evaluating a nearly
2026 forbidden module.
2027 * Add the ``debug2`` verbosity level, to report each call of
2028 :file:`modulecmd.tcl` internal procedures in addition to debug messages.
2029 Debug2 mode can be enabled by setting the :mconfig:`verbosity` config to the
2030 ``debug2`` value or by using the :option:`-D` command-line switch twice.
2031 * Install: look for ``make`` rather ``gmake`` on MinGW and build library with
2032 a ``.dll`` extension on this platform.
2033 * Add the ``trace`` verbosity level, to report details on module searches,
2034 resolutions, selections and evaluations. Trace mode can be enabled by
2035 setting the ``verbosity`` config to the ``trace`` value or by using the
2036 :option:`-T`/:option:`--trace` command-line switches.
2037 * Introduce the ``tr`` key in the color palette to specifically render trace
2038 messages. Default value for ``tr`` key is ``2`` (decreased intensity).
2039 * When trying to set an environment variable to an empty value on the Windows
2040 platform, unset this environment variable instead to cope with the
2041 underlying OS behavior.
2042
2043
2044 .. _4.5 release notes:
2045
2046 Modules 4.5.3 (2020-08-31)
2047 --------------------------
2048
2049 * Install: take into account the ``--build``, ``--host``, ``--target``,
2050 ``--enable-dependency-tracking`` and ``--disable-dependency-tracking``
2051 configure options to transmit them to the :file:`configure` scripts of
2052 Modules Tcl extension library and Modules compatibility version. (fix issue
2053 #354)
2054 * Install: ignore some regular options of an Autoconf :file:`configure` script
2055 that are useless for this project but usually implied in build macros (like
2056 RPM ``%configure`` macro).
2057 * Install: ignore unsupported ``--enable-*`` and ``--with-*`` options on
2058 :file:`configure` script rather raise an error and add support to define
2059 environment variable and build system type as :file:`configure` script
2060 arguments to comply with `GNU configuration recommendations`_.
2061 * Install: fix :file:`modulecmd` pre-alternatives check in RPM spec file.
2062 * Install: use ``%make_build`` and ``%make_install`` macros in RPM spec file.
2063 * When :mfcmd:`module switch<module>` command is used in modulefile, do not
2064 state when processing it a conflict over switched-off module if its
2065 specification on the ``module switch`` command also matches switched-on
2066 module's specification. Allow this way the replacement of any loaded version
2067 of a module for a specific one required by currently loading module. (fix
2068 issue #355)
2069 * Correctly report failed attempts to load module requirements expressed with
2070 advanced version specifiers. (fix issue #356)
2071
2072 .. _GNU configuration recommendations: https://www.gnu.org/prep/standards/html_node/Configuration.html
2073
2074
2075 Modules 4.5.2 (2020-07-30)
2076 --------------------------
2077
2078 * Init: :subcmd:`list` and :subcmd:`source` sub-commands do not take available
2079 modules as argument in fish completion script.
2080 * Init: fix option list for :subcmd:`search` sub-command in bash completion
2081 script.
2082 * Fix double error counter increase when modulefile evaluation breaks.
2083 * Install: adapt :file:`configure` script to pass to the :file:`configure`
2084 script of Modules compatibility version only a subset of the options it
2085 supports (most commonly used options).
2086 * Install: raise an error when an unknown option is passed to
2087 :file:`configure` script rather silently ignore it. (fix issue #348)
2088 * Install: enable the definition of installation directory options of
2089 :file:`configure` script with the ``--option value`` syntax in addition to
2090 the ``--option=value`` syntax. (fix issue #348)
2091 * Doc: alphabetically sort sub-commands of :mfcmd:`module-info` modulefile Tcl
2092 command in :ref:`modulefile(5)` document.
2093 * Script: clean previously built environment-modules RPMs in :command:`mrel`.
2094 * Clearly separate quarantine variable definition from tclsh binary on
2095 :file:`modulecmd.tcl` evaluated command call in ``_module_raw`` function for
2096 *sh*, *bash*, *ksh* and *zsh* shells. (fix issue #350)
2097 * Doc: clarify in documentation index that Environment Modules should not be
2098 confused with language-specific modules. (contribution from Rob Hurt)
2099 * Adapt conflict detection tests to ensure a module loaded by its full
2100 pathname will not detect itself as a conflict when declaring a reflexive
2101 conflict. (fix issue #352)
2102 * Adapt the :command:`mrel` and :command:`mpub` commands to produce new
2103 Modules release from a *vZ.Y.x* git branch rather than from the repository
2104 main branch.
2105
2106
2107 Modules 4.5.1 (2020-06-01)
2108 --------------------------
2109
2110 * Install: consistently output Makefile warning messages on stderr.
2111 * Script: add the ``mrel`` script, that automates build of the Modules release
2112 files and performs tests over these distribution files to guaranty their
2113 correctness.
2114 * Script: add the ``mpub`` script, that automates Modules new release
2115 publishing over git repositories and websites.
2116 * Install: remove project-specific tools from git repository export thus from
2117 release distribution files.
2118 * Disable pager when ``clear`` sub-command is called from ``ml`` shortcut
2119 command. (fix issue #338)
2120 * In case a modulefile evaluation fails, environment context prior this failed
2121 evaluation is restored. Fix environment variable restoration mechanism to
2122 keep the link that monitors and updates environment variable array ``env``
2123 in every Tcl sub-interpreters. (fix issue #340)
2124 * Ensure environment variable change at the Tcl interpreter level is
2125 propagated to every sub-interpreters used to evaluate modulefiles or
2126 modulercs. (fix issue #342)
2127 * Use absolute path to load Modules Tcl extension library. (fix issue #344
2128 with contribution from Roy Storey)
2129 * Fix formatting of error stack trace not to look for internal commands to
2130 withdraw if start-up stack pattern cannot be matched.
2131
2132
2133 Modules 4.5.0 (2020-04-07)
2134 --------------------------
2135
2136 * Doc: fix typos and grammar mistakes on :ref:`module(1)`,
2137 :ref:`modulefile(5)` and :ref:`changes` documents. (contribution from Colin
2138 Marquardt)
2139 * Doc: update cookbook recipes to highlight code of the Tcl scripts included.
2140 (contribution from Colin Marquardt)
2141 * Doc: improve markup of :ref:`module(1)`, :ref:`modulefile(5)` and
2142 :ref:`changes` documents to enable references to module sub-commands,
2143 command line switches, environment variables and modulefile Tcl commands.
2144 (contribution from Colin Marquardt)
2145 * Doc: alphabetically sort module sub-commands, command-line switches,
2146 environment variables and modulefile Tcl commands in :ref:`module(1)` and
2147 :ref:`modulefile(5)` documents.
2148 * Introduce the ``ml`` command, a handy frontend to the ``module`` command.
2149 ``ml`` reduces the number of characters to type to trigger ``module``. With
2150 no argument ``ml`` is equivalent to ``module list``, ``ml mod`` corresponds
2151 to ``module load mod`` and ``ml -mod`` means ``module unload mod``. Multiple
2152 modules to either load or unload can be combined on a single command. ``ml``
2153 accepts all command-line switches and sub-commands accepted by ``module``
2154 command. ``ml`` command is defined by default. Its definition can be
2155 controlled at ``./configure`` time with :instopt:`--enable-ml` option or
2156 later on with :mconfig:`ml` configuration option (which defines
2157 ``MODULES_ML`` environment variable when set).
2158 * Fix module sub-command abbreviation match to ensure passed abbreviated
2159 form fully match sub-command, not only its minimal abbreviated form. As an
2160 example, ``lod`` or ``loda`` do not match anymore the ``load``
2161 sub-command, ``lo`` or ``loa`` still do.
2162 * Add the ``-j``/``--json`` command line switches to the ``avail``, ``list``,
2163 ``savelist``, ``whatis`` and ``search`` module sub-commands to render their
2164 output in `JSON`_ format. (fix issue #303)
2165 * Script: remove need to build project management-specific tools
2166 (``mtreview``, ``mb``, ``mlprof`` and ``playdemo``) prior using them.
2167 * Script: gather all distributed and maintained scripts in a ``script``
2168 directory at the root of the project repository tree.
2169 * Install: provide Windows-specific batch files when ``./configure`` option
2170 :instopt:`--enable-windows-support` is set. module command wrapper
2171 ``module.cmd`` is installed in ``bindir`` and initialization script
2172 ``cmd.cmd`` in ``initdir``. Those batch files are relocatable and expect
2173 ``modulecmd.tcl`` in ``..\libexec`` directory. (fix issue #272 with
2174 contribution from Jacques Raphanel)
2175 * Install: add ml command wrapper ``ml.cmd`` and install it in ``bindir`` when
2176 ``./configure`` option :instopt:`--enable-windows-support` is set.
2177 * Install: introduce envml command wrapper ``envml.cmd`` for Windows ``cmd``
2178 shell and install it in ``bindir`` when ``./configure`` option
2179 :instopt:`--enable-windows-support` is set. (contribution from Jacques
2180 Raphanel)
2181 * Doc: improve documentation portal index.
2182 * Install: add ``dist-win`` target to Makefile in order to build a
2183 distribution zipball containing the required files to run Modules on a
2184 Windows platform. ``INSTALL.bat`` and ``UNINSTALL.bat`` Windows batch files
2185 are introduced and shipped in the zipball to automate installation and basic
2186 configuration of Modules on the Windows platform.
2187 * Doc: update :ref:`INSTALL-win` document to describe how to install Modules
2188 with newly provided Windows-specific distribution zipball.
2189 * Install: enable build of Modules from ``git archive`` tarball or zipball
2190 exports (like download source archives automatically provided on GitHub
2191 project)
2192 * Install: ship reStructuredText and MarkDown source documents at the root of
2193 Modules distribution tarball rather their built txt counterpart.
2194 * Script: fix ``createmodule.sh`` script to correctly analyses environment
2195 when shell functions are found defined in it.
2196 * Script: inhibit output generated by scripts evaluated by ``createmodule.sh``
2197 and ``createmodule.py`` to ensure these outputs will not get in the way when
2198 analyzing the environment changes. (fix issue #309)
2199 * Correctly handle symbolic version target including a whitespace in their
2200 name.
2201 * Testsuite: output test error details whatever the testsuite run verbose
2202 mode.
2203 * Install: adapt configure script and Makefile to detect ``python`` command
2204 location and set it as shebang for ``createmodule.py`` and
2205 ``gitlog2changelog.py``. If ``python`` command is not found, ``python3``
2206 then ``python2`` are searched.
2207 * Install: enable to pass a specific Python interpreter command name or
2208 location at configure step with :instopt:`--with-python` option. Specified
2209 command name or location should be found on build system only if building
2210 from git repository.
2211 * Install: build ``createmodule.py`` script and install it in ``bindir``.
2212 * Install: update RPM spec file to explicitly define Python interpreter
2213 location.
2214 * Script: fix ``createmodule.py`` script for Python3 (fix issue #315 with
2215 contribution from Armin Wehrfritz)
2216 * Lift Perl variable strictness when defining ``_mlstatus`` variable in case
2217 ``modulecmd.tcl`` output is directly evaluated without use of the ``module``
2218 sub-routine in Perl script. (with contribution from Andrey Maslennikov)
2219 * Script: fix path de-duplication in ``createmodule.sh``. (fix issue #316)
2220 * Doc: add *Handling Compiler and other Package Dependencies* cookbook
2221 recipe, which discusses various strategies for creating modulefiles for
2222 packages with multiple builds depending on previously loaded compiler,
2223 MPI libraries, etc. (contribution from Tom Payerle)
2224 * Init: test availability of ``compopt`` Bash builtin prior using it in
2225 Bash completion script to avoid error with versions of this shell older
2226 than 4.0. (fix issue #318)
2227 * Install: adapt configure step to detect if ``sed`` option ``-E`` is
2228 supported and fallback to ``-r`` otherwise in shell completion scripts.
2229 (fix issue #317)
2230 * Add support for the ``NO_COLOR`` environment variable
2231 (https://no-color.org/) which when set (regardless of its value) prevents
2232 the addition of ANSI color. When set, ``NO_COLOR`` prevails over
2233 ``CLICOLOR`` and ``CLICOLOR_FORCE`` environment variables. ``MODULES_COLOR``
2234 overrides these three variables. (fix issue #310)
2235 * Script: when analyzing environment variable changes in ``createmodule.sh``
2236 applied by shell script passed as argument, produce a ``setenv`` modulefile
2237 statement for any variable found set prior script evaluation and for which
2238 value is completely changed after script evaluation. (fix issue #320)
2239 * When an error message is composed of multiple lines, render it in the same
2240 way whether it is part of a block message or not: lines after the first one
2241 are prepended with a 2-space padding. As a result error messages appear
2242 clearly separated from each other.
2243 * Append to the error message the error stack trace when a general unknown
2244 error occurs in ``modulecmd.tcl`` and provide a link to encourage users to
2245 report such error to the GitHub project.
2246 * Add to the error message the error stack trace for errors occurring during
2247 site-specific configuration evaluation. Error stack is expunged from the
2248 ``modulecmd.tcl`` internals to only report information relevant to
2249 site-specific configuration file.
2250 * When an error occurs during the evaluation of a modulefile or a modulerc,
2251 report associated error stack trace expunged from ``modulecmd.tcl`` internal
2252 references to only output useful information for users.
2253 * GitHub: add issue templates to guide people submitting a bug report or a
2254 feature request.
2255 * Doc: provide a link toward issues that have been fixed between versions 3.2
2256 and 4.0 in :ref:`changes` document.
2257 * Script: introduce ``envml.cmd`` script for Windows platform providing
2258 similar behavior than ``envml`` Bash script. (contribution from Jacques
2259 Raphanel)
2260 * Init: add Bash shell completion for the ``ml`` command. (contribution from
2261 Adrien Cotte)
2262 * Fix Fish shell stderr redirection for newer Fish versions. (fix issue #325)
2263 * Correctly handle modulefiles and modulepaths containing a space character in
2264 their name whether they are used from the command-line, in collections,
2265 within modulefiles or from loaded environment definitions.
2266 * Doc: add *Default and latest version specifiers* design note.
2267 * An ``avail`` search over a symbolic version targeting a directory now
2268 correctly returns the special modules (alias and virtual module) lying in
2269 this directory. (fix issue #327)
2270 * ``whatis`` and ``paths`` searches only return special modules (symbolic
2271 version, alias and virtual modules) that fully match search query, not
2272 those that partially match it. (fix issue #328)
2273 * alias and virtual module whose name mention a directory that does not
2274 exists are correctly handled. (fix issue #168)
2275 * Hide special modules (aliases, symbolic versions and virtual modules)
2276 whose version name starts with a dot character (``.``) from ``avail``,
2277 ``whatis`` and ``paths`` searches if their query does not fully match
2278 special module name. (fix issue #329)
2279 * Filter-out from the output of the ``aliases`` sub-command all hidden
2280 aliases, symbolic versions or hidden modules targeted by a non-hidden
2281 symbolic version. (fix issue #330)
2282 * Enable resolution of default module in module sub-directory when this
2283 default symbol targets a hidden directory (whose name starts with a dot
2284 character). (fix issue #331)
2285 * Doc: clarify hidden module location in :ref:`modulefile(5)` man page.
2286 * Install: define ``LD_PRELOAD`` as quarantine var along with
2287 ``LD_LIBRARY_PATH`` in RPM specfile.
2288 * When :mconfig:`implicit_default` and :mconfig:`advanced_version_spec`
2289 configuration are enabled, automatically define a ``default`` and ``latest``
2290 symbolic version for each module name (at each module depth for deep
2291 modules) if those version names does not already exist. (fix issue #210)
2292 * Once a module is loaded, the automatically defined symbols associated to it
2293 are recorded in loaded environment in the ``MODULES_LMALTNAME`` environment
2294 variable. They are distinguished from the other alternative names applying
2295 to the module by a ``as|`` prefix, which qualifies their *auto symbol* type.
2296 * When an advanced version specifier list contains symbolic version
2297 references, fix resolving to honor default version if part of the specified
2298 list. (fix issue #334)
2299
2300 .. _JSON: https://tools.ietf.org/html/rfc8259
2301
2302
2303 .. _4.4 release notes:
2304
2305 Modules 4.4.1 (2020-01-03)
2306 --------------------------
2307
2308 * Fix error and warning messages relative to dependency management to enclose
2309 dependency specification in single quotes to clearly distinguish
2310 specification from each other.
2311 * Skip output of module loading message if module is already loaded.
2312 * Doc: add demonstration material played at SC19 to promote the new features
2313 of Modules.
2314 * Contrib: add ``playdemo`` script to play recorded demonstration cast.
2315 * Doc: add a web anchor to each modulefile Tcl command, module sub-command
2316 and module environment variable documentation.
2317 * Install: update RPM spec file to enable build on ``el8``.
2318 * Doc: fix RST syntax for bullet lists in design docs. (fix issue #306)
2319 * In case ``module avail`` query does not match a directory but only its
2320 contained elements (for instance ``module av mod/7`` matches ``mod/7.1`` and
2321 ``mod/7.2`` but not ``mod/``), fix query processing to correctly return
2322 latest or default element in case ``--latest`` or ``--default`` flags are
2323 set.
2324 * In case a ``module avail`` query performed in a no-indepth mode with
2325 ``--latest`` or ``--default`` flags either enabled or disabled, fix query
2326 processing to return directory elements if they are part of result.
2327 * When a ``module avail`` query performed in no-indepth mode targets a virtual
2328 module, fix result to filter-out the directory holding the virtual module
2329 from result.
2330 * Fix ``module avail --default`` queries when modulefile default version does
2331 not match query: select latest version from modulefiles matching query
2332 unless ``implicit_default`` configuration is disabled in which case no
2333 default version is returned.
2334 * Improve highlighting of module ``avail`` and ``whatis`` search result by
2335 coloring module names matching search query expressed with the advanced
2336 version specifiers. ``name@1,3`` or ``name@1:3`` queries now highlight
2337 ``name/1`` and ``name/3`` strings found in search result.
2338 * Contrib: add the ``mlprof`` script which wraps ``modulecmd.tcl`` to collect
2339 profiling information on its execution.
2340 * Contrib: adapt ``mb`` script to profile ``modulecmd.tcl`` run tests rather
2341 bench them when ``profile`` argument is passed to the script.
2342 * Improve overall performances of module names and versions comparison by
2343 introducing optimized procedures and caching in memory module search
2344 results.
2345
2346
2347 Modules 4.4.0 (2019-11-17)
2348 --------------------------
2349
2350 * Doc: add *Return file basename on module-info name for full path modulefile*
2351 recipe to cookbook. (fix issue #297)
2352 * Rework internal handling of configuration options to gather all option
2353 definitions in a global array and use the same initialization and retrieval
2354 procedure, named ``getConf``, for all these options.
2355 * Add the ``setConf``, ``unsetConf`` and ``lappendConf`` procedures to provide
2356 unified ways to set the value of configuration option. These procedures
2357 should be used in site configuration files to override configuration option
2358 value instead of directly setting corresponding option variable as it was
2359 done in previous Modules releases.
2360 * Add the ability to match module specification in a case insensitive manner.
2361 Default case sensitiveness behavior is set at ``./configure`` time with the
2362 ``--with-icase`` option. It could be superseded with the ``MODULES_ICASE``
2363 environment variable, that could be set with ``config`` module sub-command
2364 through the ``icase`` option. Command-line switch ``--icase`` (``-i``)
2365 enables to supersede defined case sensitiveness configuration. (fix issue
2366 #212 with contribution from Eric Deveaud)
2367 * Introduce the extended default mechanism, to help selecting a module when
2368 only the first numbers in its version are specified. Starting portion of the
2369 version, part separated from the rest of the version string by a ``.``
2370 character, will get matched to the appropriate complete version name. In
2371 case multiple versions match partial version specified and only one module
2372 should be returned, default version (implicit or explicit) among matches is
2373 returned. In case ``implicit_default`` option is disabled and no explicit
2374 default is found among matches, an error is returned. This mechanism is
2375 enabled through a new configuration option named ``extended_default`` (which
2376 defines ``MODULES_EXTENDED_DEFAULT`` environment variable when set). It may
2377 be enabled by default in ``modulecmd.tcl`` script with option
2378 ``--enable-extended-default`` passed to the ``./configure`` script.
2379 * Introduce the advanced module version specifiers mechanism to specify finer
2380 constraints on module version. This new feature enables to filter the module
2381 selection to a given version list or range by specifying after the module
2382 name a version constraint prefixed by the ``@`` character. It leverages the
2383 version specifier syntax of the `Spack`_ package manager. A single version
2384 can be specified with the ``@version`` syntax, a list of versions with
2385 ``@version1,version2,...``, a greater than or equal to range with
2386 ``@version1:`` syntax, a less than or equal to range with ``@:version2`` and
2387 an in between or equal to range with ``@version1:version2`` syntax. In case
2388 ``implicit_default`` option is disabled and no explicit default is found
2389 among version specifier matches, an error is returned. This mechanism is
2390 enabled through a new configuration option named ``advanced_version_spec``
2391 (which defines ``MODULES_ADVANCED_VERSION_SPEC`` environment variable when
2392 set). It may be enabled by default in ``modulecmd.tcl`` script with option
2393 ``--enable-advanced-version-spec`` passed to the ``./configure`` script.
2394 * Conflict defined with a generic module name or an advanced version specifier
2395 may match multiple loaded modules (generally in case multiple loaded modules
2396 share same root name). Loaded environment analysis has been fixed to bind
2397 conflict to all loaded modules matching it. As a result the *Dependent
2398 Reload* mechanism is not triggered when one loaded module matching conflict
2399 is removed if another loaded module still match the conflict.
2400 * Doc: add *Module selection contexts*, *Insensitive case*, *Extended default*
2401 and *Advanced module version specifiers* design notes.
2402 * Make ``MODULESHOME`` environment variable controllable through the
2403 ``config`` sub-command with ``home`` configuration option. A
2404 ``--with-moduleshome`` argument is also added to the ./configure script to
2405 set specific default value for this option at installation time. (fix issue
2406 #292)
2407
2408 .. _Spack: https://github.com/spack/spack
2409
2410
2411 .. _4.3 release notes:
2412
2413 Modules 4.3.1 (2019-09-21)
2414 --------------------------
2415
2416 * Contrib: add ``mb`` script to bench Modules versions.
2417 * Correct ``modulecmd.tcl`` script startup to correctly report error in case
2418 Tcl extension library fails to load. (fix issue #284)
2419 * Install: fix typo on ``CFLAGS`` definition in ``lib/Makefile``. (fix issue
2420 #287 with contribution from Felix Neumärker)
2421 * Remove useless code in Modules Tcl extension library
2422 * Make URLs in README correctly rendered in HTML. (contribution from Per
2423 Persson)
2424 * Doc: clarify modulefile evaluation modes in modulefile.4 man page. (fix
2425 issue #289)
2426 * When looking at the closest match among loaded modules when switching module
2427 with just a single module argument specified, load the information on the
2428 currently set environment to get the alternative names of loaded modules
2429 prior to look at closest module match. (fix issue #290)
2430 * Doc: describe the way to determine the site-specific configuration script
2431 location in cookbook recipes implying the installation of such a file. (fix
2432 issue #266)
2433 * Doc: add *Log module command* recipe to cookbook. (fix issue #283)
2434 * Doc: add *Expose procedures and variables to modulefiles* recipe to
2435 cookbook.
2436 * Doc: add *Make defined modulepaths persist over sudo* recipe to cookbook.
2437 * Doc: add *Ensure user fully qualify the modules they use* recipe to
2438 cookbook.
2439 * Introduce the ``wa_277`` configuration option to workaround an issue with
2440 Tcsh history mechanism. Default ``module`` alias definition for Tcsh hits
2441 an issue with shell history mechanism: erroneous history entries are
2442 recorded each time the ``module`` command is called. When ``wa_277`` option
2443 is enabled (which sets the ``MODULES_WA_277`` environment variable to *1*),
2444 an alternative module alias is defined which fixes the history mechanism
2445 issue. However the alternative definition of the module alias weakens shell
2446 evaluation of the code produced by modulefiles. Characters with special
2447 meaning for Tcsh shell (like *{* and *}*) may not be used anymore in shell
2448 alias definition elsewhere the evaluation of the code produced by
2449 modulefiles will return a syntax error. (fix issue #277)
2450 * Doc: add *Tips for Code Reuse in Modulefiles* recipe to cookbook.
2451 (contribution from Tom Payerle)
2452 * Fix the ``whatis`` and ``paths`` sub-command results for module symbolic
2453 versions targeting a directory when ``implicit_default`` configuration
2454 option is disabled. No error is returned and same result is now obtained
2455 whether the symbolic name or its target is used as argument for those two
2456 sub-commands. (fix issue #294)
2457 * Fix the ``whatis`` and ``paths`` sub-command results for module aliases
2458 targeting a directory when ``implicit_default`` configuration option is
2459 disabled. No error is returned and same result is now obtained whether the
2460 alias name or its target is used as argument for those two sub-commands.
2461 (fix issue #295)
2462 * Rework all the ternary operator expressions in ``modulecmd.tcl`` that may
2463 result in a *nan* value (whatever the case used to write this string) as the
2464 ``expr`` Tcl command raises an error when it returns such a value, which
2465 breaks Modules as soon as a modulefile, an alias or a symbolic version is
2466 named *nan*. (fix issue #296)
2467
2468
2469 Modules 4.3.0 (2019-07-26)
2470 --------------------------
2471
2472 * Introduce Vim addon files to highlight the modulefile syntax. Installation
2473 of these files, which is enabled by default, is controlled by the
2474 ``--enable-vim-addons`` and ``--vimdatadir`` configure options.
2475 (contribution from Felix Neumärker)
2476 * If modulefile is fully read, cache the content read and the file header
2477 computed to avoid another file read if the same modulefile need to be read
2478 multiple times.
2479 * Except for path, paths, list, avail and aliases module commands always fully
2480 read a modulefile whether its full content is needed or just its header to
2481 verify its validity. Proceed this way to only read file once on commands
2482 that first just check modulefile validity then read again valid files to get
2483 their full content.
2484 * Introduce Modules Tcl extension library (written in C) to extend Tcl
2485 language in order to provide more optimized I/O commands to read a file or a
2486 directory content than native Tcl commands do.
2487 * Install: add ``--libdir``, ``--enable-libtclenvmodules``, ``--with-tcl`` and
2488 ``--with-tclinclude`` options to configure script to control
2489 libtclenvmodules build and installation.
2490 * When an error is caught during modulecmd.tcl first initialization steps,
2491 ensure the error report facility is initialized to render error message.
2492 * When looking for modulefiles in enabled modulepaths, take ``.modulerc`` file
2493 found at the root of a modulepath directory into account. Which means these
2494 rc files are now evaluated like global rc files and can be used to define
2495 module aliases targeting modulefiles stored in the underlying file tree.
2496 * Correctly get available default (-d) and latest (-L) version whether search
2497 pattern is passed with an ending forward slash character or not or if it
2498 contains a ``*`` wildcard character.
2499 * Append a forward slash character to any directory result of an avail command
2500 to better distinguish these directories from regular files.
2501 * Introduce the ability to control whether ``avail`` command search results
2502 should recursively include or not modulefiles from directories matching
2503 search query by use of the ``--indepth`` and ``--no-indepth`` command-line
2504 switches or the environment variable ``MODULES_AVAIL_INDEPTH``. Default
2505 behavior is set at the ``./configure`` time with the
2506 ``--enable-avail-indepth`` and ``--disable-avail-indepth`` switches. (fix
2507 issue #150)
2508 * Update ``bash``, ``fish`` and ``zsh`` completion scripts to propose
2509 available modulefiles in the no in depth mode.
2510 * Add the ability to graphically enhance some part of the produced output to
2511 improve readability by the use of the ``--color`` command-line switch or the
2512 ``MODULES_COLOR`` environment variable. Both accept the following values:
2513 ``never``, ``auto`` and ``always``. When color mode is set to ``auto``,
2514 output is colored if stderr is attached to a terminal. Default color mode
2515 could be controlled at configure time with the ``--enable-color`` and the
2516 ``--disable-color`` option, which respectively correspond to the ``auto``
2517 and ``never`` color mode.
2518 * Control the color to apply to each element with the ``MODULES_COLORS``
2519 environment variable or the ``--with-dark-background-colors`` and
2520 ``--with-light-background-colors`` configure options. These variable and
2521 options take as value a colon-separated list in the same fashion
2522 ``LS_COLORS`` does. In this list, each element that should be highlighted is
2523 associated to a Select Graphic Rendition (SGR) code.
2524 * Inform Modules of the terminal background color with the
2525 ``MODULES_TERM_BACKGROUND`` environment variable or the
2526 ``--with-terminal-background`` configure option, which helps to determine if
2527 either the dark or light background colors should be used to color output in
2528 case no specific color set is defined with the ``MODULES_COLORS``.
2529 * Color prefix tag of debug, error, warning, module error and info messages.
2530 * Highlight the modulefile or collection name when reporting messages for a
2531 an action made over this modulefile or collection.
2532 * Color the modulepaths reported on a ``use`` command.
2533 * Highlight title of separator lines or column name of table header.
2534 * Color modulepaths, directories, aliases and symbols reported by the
2535 ``avail``, ``aliases``, ``list``, ``whatis`` and ``search`` commands.
2536 * When color mode is enabled and module aliases are colored, do not associate
2537 them a ``@`` tag as the color already distinguish them from regular
2538 modulefile.
2539 * When color mode is enabled and a Select Graphic Rendition (SGR) code is set
2540 for the ``default`` modulefile symbol, apply this SGR code to the modulefile
2541 name instead of associating it the ``default`` symbol tag.
2542 * Highlight matched module search query string among ``avail``, ``whatis`` and
2543 ``search`` command results.
2544 * Highlight the modulefile and collection full path name on ``display``,
2545 ``help``, ``test`` and ``saveshow`` command reports.
2546 * Color modulefile Tcl commands set in a modulefile on a ``display`` command
2547 report.
2548 * Color module commands set in a collection on a ``saveshow`` command report.
2549 * Re-introduce ``clear`` sub-command. (fix issue #203)
2550 * Leverage ``--force`` command-line switch on ``clear`` sub-command to skip
2551 confirmation dialog. (fix issue #268)
2552 * Init: improve readability of variable definition operations by writing one
2553 definition operation per line rather having multiple commands on a single
2554 line like ``VAR=val; export VAR``. (fix issue #225)
2555 * Add the ability to define a site-specific configuration file with an
2556 environment variable: ``MODULES_SITECONFIG``. When set, the script file
2557 pointed by the variable is sourced (if readable) after the site-specific
2558 configuration file initially defined in ``modulecmd.tcl``. (contribution
2559 from Ben Bowers, fix issue #234)
2560 * Doc: add description in the module.1 man page of ``MODULERCFILE`` in the
2561 environment section and ``siteconfig.tcl`` in the files section.
2562 * Install: provide at installation time a bare site-specific configuration
2563 script in designated ``etcdir`` if no pre-existing ``siteconfig.tcl`` file
2564 is found at designated location.
2565 * Introduce the ``config`` sub-command to get and set ``modulecmd.tcl``
2566 options and to report its current state.
2567 * Contrib: update ``createmodule.py`` script to support execution from the
2568 *cmd* shell. (contribution from Jacques Raphanel, fix issue #270)
2569 * Add the ability to configure when unloading a module and multiple loaded
2570 modules match request if firstly loaded module should be chosen or lastly
2571 loaded module. Configure option ``--with-unload-match-order`` defines this
2572 setting which can be superseded with the ``MODULES_UNLOAD_MATCH_ORDER``
2573 environment variable. This variable can be set with the option
2574 ``unload_match_order`` on the ``config`` sub-command. By default, lastly
2575 loaded module is selected. It is recommended to keep this behavior when the
2576 modulefiles used express dependencies between each other.
2577 * Add the ability to configure whether an implicit default version should be
2578 defined for modules with no default version explicitly defined. When
2579 enabled, which stays the default behavior, a module version is automatically
2580 selected (latest one) when the generic name of the module is passed. When
2581 implicit default selection is disabled, the name of modules to evaluate
2582 should be fully qualified elsewhere an error is returned. This option is set
2583 at ``./configure`` time with the ``--enable-implicit-default`` and
2584 ``--disable-implicit-default`` options. It could be superseded with the
2585 ``MODULES_IMPLICIT_DEFAULT`` environment variable, that could be set with
2586 ``config`` module sub-command through the ``implicit_default`` option.
2587 * Install: add to the configure script the ``--with-locked-configs`` option to
2588 ignore environment variable superseding of Modules configurations defined in
2589 ``modulecmd.tcl`` script. Lockable configuration option are
2590 ``extra_siteconfig`` and ``implicit_default``. Currently locked options are
2591 reported through the ``locked_configs`` option on the ``config``
2592 sub-command.
2593 * Introduce the ability to control the module search match. Search query
2594 string should match module name start or any part of module fully qualified
2595 name. Default search match behavior is set at ``./configure`` time with the
2596 ``--with-search-match`` option. It could be superseded with the
2597 ``MODULES_SEARCH_MATCH`` environment variable, that could be set with
2598 ``config`` module sub-command through the ``search_match`` option.
2599 Command-line switches ``--starts-with`` (``-S``) and ``--contains`` (``-C``)
2600 for ``avail`` module sub-command enable to supersede defined search match
2601 configuration.
2602 * Introduce the ability not to set the shell startup file that ensure
2603 ``module`` command is defined once shell has been initialized. Setting shell
2604 startup file currently means defining ``ENV`` and ``BASH_ENV`` environment
2605 variables to the Modules bourne shell initialization script. ``./configure``
2606 options ``--enable-set-shell-startup`` and ``--disable-set-shell-startup``
2607 define if shell startup should be set or not by default. It could be
2608 superseded with the ``MODULES_SET_SHELL_STARTUP`` environment variable, that
2609 could be set with ``config`` module sub-command through the
2610 ``set_shell_startup`` option.
2611 * Cookbook: add the *test-modulefiles* recipe. (fix issue #182 with
2612 contribution from Colin Marquardt)
2613 * Fix location of global RC file to ``@etcdir@/rc`` instead of
2614 ``@prefix@/etc/rc`` to cope with ``@etcdir@`` specific setup (``@etcdir@``
2615 defaults to ``@prefix@/etc``).
2616 * Take into account Modules initialization configurations found in ``etc``
2617 directory if they exist rather in ``init`` directory. If ``initrc``
2618 configuration file is found in ``etcdir`` then it is preferred over
2619 ``modulerc`` file in ``initdir``. Following the same trend, ``modulespath``
2620 configuration file is found in ``etcdir`` then it is preferred over
2621 ``.modulespath`` file in ``initdir``.
2622 * Introduce the ability to install the Modules initialization configuration
2623 files in the ``etcdir`` rather than in the ``initdir``. A new configure
2624 option is introduced for this task: ``--with-initconf-in``. Accepted values
2625 for this option are: ``etcdir`` or ``initdir`` (default).
2626 * Add the ``--enable-modulespath`` configure option, which is an alias for the
2627 ``--enable-dotmodulespath`` option as ``.modulespath`` configuration file is
2628 named ``modulespath`` when installed in ``etcdic``.
2629 * Install: update RPM spec file to disable ``set_shell_startup`` option by
2630 default, set ``/etc/environment-modules`` as configuration directory and
2631 store Modules initialization configuration files in it.
2632 * Report an error when a module load or unload evaluation aborts due to the
2633 use of the ``break`` or ``exit`` modulefile commands. This error
2634 notification clarifies that module evaluation failed. (fix issue #267)
2635 * Remove the message block display output for the ``reload``, ``purge`` and
2636 ``restore`` sub-commands to preserve this output style for modulefile
2637 evaluation modes (load, unload and switch) and thus clarify understanding.
2638 * When unloading a module that contains a ``module load`` or ``module switch``
2639 modulefile command, inhibit the unload performed of the useless requirement
2640 when auto_handling mode is disabled if currently performing a ``purge``,
2641 ``reload`` or ``restore`` sub-command. As the unload sequence is determined
2642 and managed from these top commands.
2643 * Add ability to control module command message verbosity with configuration
2644 option. Introduced verbosity levels from the least to the most verbose are
2645 ``silent``, ``concise``, ``normal``, ``verbose`` and ``debug``. This option
2646 could be set at ``./configure`` time with ``--with-verbosity`` option.
2647 It could be superseded with the ``MODULES_VERBOSITY`` environment variable,
2648 that could be set with ``config`` module sub-command through the
2649 ``verbosity`` option. Silent, verbose and debug verbosity modes can be set
2650 at the command-line level respectively with ``--silent``/``-s``,
2651 ``--verbose``/``-v`` and ``--debug``/``-D`` command-line switches. (fix
2652 issue #204)
2653 * When verbosity level is ``normal`` or higher, reports every module loads or
2654 unloads performed to ``restore`` a collection or ``source`` a scriptfile,
2655 even if there is no specific message to output for these module evaluations.
2656 Clarifies what module evaluations have been triggered by these sub-commands.
2657 * Also honor the ``CLICOLOR`` and ``CLICOLOR_FORCE`` environment variables to
2658 define color mode. (fix issue #279)
2659
2660
2661 .. _4.2 release notes:
2662
2663 Modules 4.2.5 (2019-07-08)
2664 --------------------------
2665
2666 * Correctly escape ``?`` character in shell alias. (fix issue #275)
2667 * When resolving the enabled list of modulepaths, ensure resolved path
2668 entries are unique. (fix issue #274)
2669 * Right trim '#' characters from the fetched modulefile magic cookie string
2670 to ensure a correct compatibility version comparison. Useful when modulefile
2671 first line is equal to ``#%Module4.2##############``.
2672 * Fix argument parsing for the ``append-path``, ``prepend-path`` and
2673 ``remove-path`` modulefile commands to consider every arguments found after
2674 the variable name as variable values and not command option even if argument
2675 starts with ``-`` character. (fix issue #278)
2676 * Fix automatic loading of modulefiles when multiple module names are set on a
2677 single ``module load`` modulefile command. When auto_handling mode was
2678 disabled, the load of not loaded modules was not achieved as soon as some
2679 modules on this list were already loaded. (fix issue #281)
2680
2681
2682 Modules 4.2.4 (2019-04-26)
2683 --------------------------
2684
2685 * Better track each module evaluation and the context associated to it in
2686 order to report a more accurate information on the additional modules
2687 loaded or unloaded when proceeding the main evaluation request. (fix issue
2688 #244, #245, #246, #247 and #248)
2689 * Doc: preserve quotes and dashes when making HTML docs. (fix issue #250 with
2690 contribution from Riccardo Coccioli)
2691 * Fix hanging ``list`` sub-command when terminal width is equal to the single
2692 column text width to be printed. (contribution from Jesper Dahlberg)
2693 * During an additional evaluation triggered by an automated module handling
2694 mechanism, ensure warning and error messages are reported under the message
2695 block of the main evaluation. (fix issue #252)
2696 * During the unload of a module when the automated module handling mode is
2697 disabled, report a warning message for each unload of a useless requirement
2698 that fails as done when the automated module handling mode is enabled. (fix
2699 issue #253)
2700 * When multiple modules are listed on a ``prereq`` command, drop the output of
2701 those modules that fails to load (by the *Requirement Load* automated
2702 mechanism) to only keep the output of the module whose load succeed. (fix
2703 issue #254)
2704 * Fix ``switch`` sub-command when the switched-off module cannot be unloaded
2705 when other loaded modules depend on it. Whole switch process is failed and
2706 no load of the switched-on module is attempted. (fix issue #251)
2707 * When switching modules, report failure of switched-off module unload or
2708 switched-on module load under the message block of the switch action. A
2709 failed switched-off module unload is reported as an error, as it aborts the
2710 switch evaluation, whereas a failed switched-on module load is reported as a
2711 warning. (fix issue #255)
2712 * When a module requirement is seen missing but the load of this module was
2713 attempted, report a more specific error or warning message to let user
2714 understand that the load of the requirement was attempted but failed. (fix
2715 issue #257)
2716 * When loading a module, report any missing requirement on the message
2717 reporting block corresponding to this module load. This warning or error
2718 message comes in addition to the eventual *Requirement Load* message
2719 reported under the message block of the main evaluation. (fix issue #258)
2720 * When unloading a module which has some dependent module still loaded,
2721 produce a more specific error or warning message if an evaluation of these
2722 dependent modules has been realized or if the unload of the required module
2723 is forced. (fix issue #259)
2724 * When a conflicting module is seen loaded but the unload of this module was
2725 attempted, report a *Conflict Unload* error or warning message toward the
2726 main evaluation message block. (fix issue #261)
2727 * When loading a module, report any loaded conflict on the message reporting
2728 block corresponding to this module load. This warning or error message comes
2729 in addition to the eventual *Conflict Unload* message reported under the
2730 message block of the main evaluation. (fix issue #261)
2731 * Correctly report loading state of conflicting module. (fix issue #262)
2732 * Adapt warning, error and info messages relative to the *Dependent Reload*
2733 mechanism to distinguish the unload phase from the load (reload) phase of
2734 this mechanism. In the automated module handling summary report, unloaded
2735 modules via this mechanism are reported in the *Unloading dependent* list
2736 and modules reloaded afterward are reported against the *Reloading
2737 dependent* list. (fix issue #263)
2738 * When the automated module handling mode is disabled, do not attempt to load
2739 a requirement expressed in a modulefile with a ``module load`` command, if
2740 this requirement is already loaded or loading.
2741 * Skip load or unload evaluation of a module whose respectively load or unload
2742 was already attempted but failed. If this second evaluation attempt occurs
2743 within the same main evaluation frame. (fix issue #264)
2744 * When reloading modules through the *Dependent Reload* automated mechanism,
2745 prevent modules to automatically load of other modules with the ``module
2746 load`` modulefile command, as it is done for the ``prereq`` command. (fix
2747 issue #265)
2748 * Raise an error when an invalid option is set on ``append-path``,
2749 ``prepend-path`` or ``remove-path`` modulefile command. (fix issue #249)
2750 * Zsh initializes by default the ``MANPATH`` environment variable to an empty
2751 value when it starts. To preserve ``manpath`` system configuration even
2752 after addition to this variable by modulefiles, set ``MANPATH`` variable to
2753 ``:`` if found empty. (improve fix for issue #224)
2754 * Doc: provide a short installation guideline in README file. (fix issue #230)
2755
2756
2757 Modules 4.2.3 (2019-03-23)
2758 --------------------------
2759
2760 * Add all the module dependency-related internal information to those saved
2761 prior a modulefile evaluation in order to correctly restore internal state
2762 in case modulefile evaluation fails.
2763 * Init: in shell initialization scripts, initialize ``MANPATH`` if not set
2764 with a value that preserves ``manpath`` system configuration even after
2765 addition of paths to this variable by modulefiles. (fix issue#224)
2766 * Enable to define an entire path entry to the ``MODULEPATH`` variable which
2767 corresponds to a variable reference only. (fix issue#223)
2768 * Cookbook: add the *modulefiles-in-git* recipe. (contribution from Scott
2769 Johnson)
2770 * When ``module switch`` commands are found in modulefiles, track switched-off
2771 modulefile as a conflict and switched-to modulefile as a requirement to
2772 apply same behaviors than for ``module load`` and ``module unload`` commands
2773 in modulefiles. If ``module switch`` has only one argument, do not define a
2774 conflict toward switched-off modulefile. *CAUTION: it is not recommended to
2775 use module switch command in modulefiles*. (fix issue#229)
2776 * When unloading a module, revert ``module switch`` commands found in
2777 modulefile: switched-on module is converted to a ``module unload``, like for
2778 ``module load`` command. Nothing is done for switched-off module, like for
2779 ``module unload`` command. (fix issue#226)
2780 * For default element in a modulefile directory which is a module alias that
2781 points to a modulefile, when this modulefile is loaded, it receives as
2782 alternative names the eventual module aliases set on the distant directory
2783 holding the alias pointing to it. (fix issue#231)
2784 * When unloading a module that contains ``module load`` or ``module switch``
2785 commands in its modulefile, select for unload the automatically loaded
2786 requirement module which has been loaded prior its dependent. (fix
2787 issue#232)
2788 * Doc: describe Emacs settings useful for adhering to coding conventions in
2789 CONTRIBUTING guide. (fix issue #233 with contribution from Ben Bowers)
2790 * When looking for a loaded or loading dependency requirement, select among
2791 the eventual multiple candidates the closest match to the dependent module.
2792 * During the unload of a module, if the unload of one of its dependent (by the
2793 *Dependent Unload* mechanism) fails, abort the whole unload process.
2794 Exception made if the force mode is enabled. In this case failing module
2795 stays loaded and the *Dependent Unload* mechanism continues with next module
2796 to unload.
2797 * During the unload of a module, if the unload of one of its useless
2798 requirements (by the *Useless Requirement Unload* mechanism) fails, keep the
2799 requirements of this failing module loaded. Such error is reported as a
2800 warning and it does not stop the whole unload process. (fix issue#240)
2801 * During the load or the unload of a module, if the unload of one of its
2802 dependent (by the *Dependent Reload* mechanism) fails, abort the whole
2803 unload or load process. Exception made if the force mode is enabled. In this
2804 case failing module stays loaded and *Dependent Reload* mechanism continues
2805 with next module to unload. This failing module is removed from the
2806 *Dependent Reload* list, so it will not take part of the load phrase of the
2807 mechanism. (fix issue#239)
2808 * During the load or the unload of a module, if the load of one of its
2809 dependent (by the *Dependent Reload* mechanism) fails, abort the whole
2810 unload or load process. Exception made if the force mode is enabled. In this
2811 case failing module stays loaded and *Dependent Reload* mechanism continues
2812 with next module to load. When the mechanism is applied during a ``switch``
2813 command, force mode is enabled by default on the load phase. (fix issue#241)
2814 * When reloading all loaded modules with the ``reload`` sub-command, if one
2815 reloading module fails to unload or load, abort the whole reload process to
2816 preserve environment sanity. (fix issue#237)
2817 * During the unload of a module when the automated module handling mode is
2818 disabled and this module declares its requirements with the ``module load``
2819 modulefile command. If the unload of one of its useless requirements (by the
2820 *Useless Requirement Unload* mechanism) fails, whole unload process is not
2821 aborted and continue with next module to unload. (fix issue#238)
2822 * Contrib: add ``mtreview`` utility script that analyzes test suite log file
2823 to compare actual and expected output of failed test. ``mt`` does not output
2824 the full test suite logs anymore but only the information produced by
2825 ``mtreview`` on failed tests.
2826 * Install: exclude Continuous Integration configurations from dist tarballs.
2827
2828
2829 Modules 4.2.2 (2019-02-17)
2830 --------------------------
2831
2832 * Correct the *Dependent Unload* mechanism when it triggers the unload of 2
2833 modules making together a requirement from another module. This module is
2834 now also added to the dependent modules to unload.
2835 * Doc: add a cookbook section in the documentation and port there the 3
2836 pre-existing recipes: *inhibit-report-info*, *top-priority-values* and
2837 *unload-firstly-loaded*.
2838 * Doc: add a CONTRIBUTING guide.
2839 * Doc: fix a typo on the Python initialization example in module man page.
2840 * Doc: add a FAQ entry to describe the use of module from Makefile. (with
2841 contribution from Robert McLay)
2842 * Trim any white-space, newline or ``;`` characters at the beginning or end of
2843 the function body passed to set-function modulefile command.
2844 * Init: add recognition of the ``--auto``, ``--no-auto`` and ``--force``
2845 command-line switches in fish shell completion script.
2846 * Init: add recognition of the ``--auto``, ``--no-auto``, ``--force``,
2847 ``--paginate`` and ``--no-pager`` command-line switches in zsh shell
2848 completion script.
2849 * When the load of a modulefile is asked but a conflict is registered against
2850 this modulefile by an already loaded module, the load evaluation is now
2851 performed and the conflict is checked after this evaluation. If the conflict
2852 is still there, this evaluation (and the evaluation of its requirements) is
2853 rolled back. (fix issue#216)
2854 * Init: fix ``_module_not_yet_loaded`` alias in tcsh completion script to
2855 handle situation when ``noclobber`` variable is set. Also ensure actual
2856 ``rm`` command is called and not an alias. (fix issue#219)
2857 * Fix warning message when the load of a modulefile is forced over a reflexive
2858 conflict (message was reported twice).
2859 * When looking at the dependency of a loaded module, only consider requirement
2860 loaded before dependent module (holding a prior position in the loaded
2861 module list) as valid. Those loaded after dependent module are considered as
2862 an unmet dependency thus they are not taking part in the *Dependent Unload*,
2863 the *Useless Requirement Unload* and the *Dependent Reload* mechanisms.
2864
2865
2866 Modules 4.2.1 (2018-11-11)
2867 --------------------------
2868
2869 * Cookbook: add the *inhibit-report-info* recipe.
2870 * Cookbook: port *unload-firstly-loaded* and *top-priority-values* recipes to
2871 v4.2.
2872 * Init: fix listing of loaded modules for *fish* and *tcsh* shell completions.
2873 * Init: fix saved collection listing when no collection found for *bash*,
2874 *zsh*, *tcsh* and *fish* shell completions.
2875 * Adapt ``system`` modulefile Tcl command to execute the command passed as
2876 argument through shell, like it is performed on compatibility version. (fix
2877 issue#205)
2878 * Correctly filter modulefile search memory cache entries when using a full
2879 search result to search later on a specific modulefile.
2880 * Prefix debug messages by information on the current modulefile or modulerc
2881 interpreter if any.
2882 * Init: fix listing of loaded modules on unload and switch sub-commands for
2883 *bash* shell completion.
2884 * Refrain ``module unload`` modulefile command from unloading a module
2885 required by another loading module.
2886 * Enable ``is-loaded`` modulefile Tcl command in modulerc interpretation
2887 context, like done on compatibility version. (fix issue#207)
2888 * Check a required module is not already loading before attempting to load it.
2889 Helps to handle cyclic dependencies.
2890 * Compute loaded modules requirement dependency relations without cycle and
2891 consider the module closing the cycle in a constraint violation state to
2892 avoid reloading loops on the *Dependent Reload* mechanism.
2893 * Safely unset dependency reference when computing dependency relations as
2894 some dependencies expressed may target same module.
2895 * Ensure a loaded module matching multiple entries of a same *or* ``prereq``
2896 will just be considered as one module matching this requirement.
2897 * Init: quote prompt in *csh* and *tcsh* script with ``:q`` rather double
2898 quotes to accommodate prompts with embedded newlines. (fix issue#209 with
2899 contribution from Satya Mishra)
2900 * Init: skip shell environment alteration if ``autoinit`` command fails. (fix
2901 issue#208)
2902 * Reword path-like variable element counter reference handling to simply
2903 ignore the counter values not coherent with the content of related
2904 path-like variable. (fix issue#206)
2905
2906
2907 Modules 4.2.0 (2018-10-18)
2908 --------------------------
2909
2910 * Add ``chdir`` and ``puts`` environment settings to the per-modulefile
2911 evaluation saved context. So previous values of these settings are restored
2912 in case of evaluation failure.
2913 * Fix save and restore of ``x-resource`` environment settings on the
2914 per-modulefile evaluation context.
2915 * Use the correct warning procedure to report the full reference counter
2916 inconsistency message (so this message is fully inhibited during global
2917 ``whatis`` evaluations).
2918 * Make ``append-path``, ``prepend-path``, ``remove-path`` and ``unsetenv``
2919 commands alter ``env`` Tcl global array during ``display``, ``help``,
2920 ``test`` or ``whatis`` evaluation modes. Thus an invalid argument passed to
2921 these commands will now raise error on these modes. (see
2922 :ref:`v42-variable-change-through-modulefile-evaluation` section in
2923 MIGRATING document)
2924 * On ``whatis`` mode, ``append-path``, ``prepend-path``, ``remove-path``,
2925 ``setenv`` and ``unsetenv`` commands initialize variables if undefined but
2926 do not set them to their accurate value for performance concern.
2927 * Clear value instead of unsetting it during an unload mode evaluation of
2928 ``setenv`` or ``*-path`` commands to avoid breaking later reference to the
2929 variable in modulefile.
2930 * Make ``getenv`` command returns value on ``help``, ``test`` or ``whatis``
2931 evaluation modes. (fix issue#188)
2932 * Add an argument to the ``getenv`` command to return the value of this
2933 argument if the queried variable is undefined.
2934 * Use a different modulefile interpreter for each evaluation mode.
2935 * Adapt the procedure called for each modulefile command depending on the
2936 evaluation mode to adapt behavior of these commands to the module command
2937 currently running.
2938 * Report calling name and arguments for modulefile commands on ``display``
2939 mode. For the commands evaluated during this mode, trigger this report at
2940 the end of the evaluation.
2941 * Inhibit ``chdir``, ``conflict``, ``module``, ``module-log``,
2942 ``module-trace``, ``module-user``, ``module-verbosity``, ``prereq``,
2943 ``set-alias``, ``system``, ``unset-alias``, ``x-resource`` commands on
2944 ``help``, ``test`` and ``whatis`` evaluation modes.
2945 * Ignore ``chdir``, ``module``, ``module-trace``, ``module-verbosity``,
2946 ``module-user`` and ``module-log`` commands found during modulerc
2947 evaluation.
2948 * Correctly restore an empty string value on sub-interpreter global variables
2949 when sanitizing this interpreter between two modulefile/modulerc
2950 evaluations.
2951 * Cache in memory results of a modulefile search to reuse it in case of rerun
2952 instead of re-walking the filesystem.
2953 * Evaluate global rc files once module sub-command is known and registered,
2954 so it can be queried during their evaluation.
2955 * Rename ``_moduleraw`` shell function in ``_module_raw`` to use a common
2956 ``_module_`` prefix for all module-related internal shell functions.
2957 * Install: add ``--enable-append-binpath`` and ``--enable-append-manpath``
2958 configure options to append rather prepend the bin or man directory when
2959 adding them to the relative environment variable.
2960 * Doc: clarify documentation for module usage on scripting language like Perl
2961 or Python to mention that arguments to the ``module`` function should be
2962 passed as list and not as a single string.
2963 * When interpreting a ``setenv`` modulefile order during an unload evaluation,
2964 variable is still set to be unset in generated shell code but it is set to
2965 the value defined on the ``setenv`` order in the interpreter context instead
2966 of being cleared.
2967 * Register the conflicts defined by loaded modules in the environment
2968 (variable ``MODULES_LMCONFLICT``) and ensure they keep satisfied. (see
2969 :ref:`v42-conflict-constraints-consistency` section in MIGRATING document)
2970 * Register the prereqs defined by loaded modules in the environment (variable
2971 ``MODULES_LMPREREQ``) and ensure they keep satisfied. (see
2972 :ref:`v42-prereq-constraints-consistency` section in MIGRATING document)
2973 * Introduce the automated module handling mode, which consists in additional
2974 actions triggered when loading or unloading a modulefile to satisfy the
2975 dependency constraints it declares. Those actions are when loading a
2976 modulefile: the *Requirement Load* and the *Dependent Reload*. When
2977 unloading a modulefile, *Dependent Unload*, *Useless Requirement Unload* and
2978 *Dependent Reload* actions are triggered. (see
2979 :ref:`v42-automated-module-handling-mode` section in MIGRATING document)
2980 * Track the loaded modules that have been automatically loaded (with
2981 environment variable ``MODULES_LMNOTUASKED``) to distinguish them from
2982 modules that have been explicitly asked by user. This information helps to
2983 determine what module becomes a useless requirement once all its dependent
2984 modules are unloaded.
2985 * Track in saved collections the loaded modules that have been automatically
2986 loaded by add of a ``--notuasked`` argument to ``module load`` collection
2987 lines. So this information is restored in loaded environment when collection
2988 is restored. This ``--notuasked`` argument is ignored outside of a
2989 collection restore context.
2990 * Consider modules loaded from a ``module source`` file as explicitly asked by
2991 user.
2992 * Install: add ``--enable-auto-handling`` configure option to enable or
2993 disable the automatic modulefile handling mechanism.
2994 * Process list of loaded modules or modules to load one by one during the
2995 ``restore``, ``purge`` and ``reload`` sub-commands whatever the auto
2996 handling mode is.
2997 * Add the ability to control whether the auto_handling mode should be enabled
2998 or disabled with an environment variable called ``MODULES_AUTO_HANDLING`` or
2999 from the command-line with ``--auto`` and ``--no-auto`` switches. These
3000 command-line switches are ignored when called from modulefile.
3001 * Init: add pager-related command-line options in shell completion scripts.
3002 * Doc: describe ``MODULES_LMCONFLICT``, ``MODULES_LMPREREQ`` and
3003 ``MODULES_LMNOTUASKED`` in module.1 man page.
3004 * Add ``-f`` and ``--force`` command-line switches to by-pass dependency
3005 consistency during ``load``, ``unload`` or ``switch`` sub-commands. (see
3006 :ref:`v42-by-passing-module-constraints` section in MIGRATING document)
3007 * Disallow collection ``save`` or loaded modules ``reload`` if some loaded
3008 modules have some of their dependency constraints unsatisfied.
3009 * The *Dependent Reload* action of a ``load``, ``unload`` and ``switch``
3010 sub-commands excludes modules that have unsatisfied constraints and includes
3011 modules whose constraints are satisfied again (when sub-command process
3012 solves a conflict for instance).
3013 * Doc: describe ``--force``, ``--auto`` and ``--no-auto`` command-line
3014 switches and ``MODULES_AUTO_HANDLING`` variable in module.1 man page.
3015 * Ignore directories ``.SYNC`` (DesignSync) and ``.sos`` (SOS) when walking
3016 through modulepath directory content. (contribution from Colin Marquardt)
3017 * Install: look for ``make`` rather ``gmake`` on MSYS2.
3018 * Fix ``exec()`` usage in Python module function definition to retrieve the
3019 correct return status on Python3.
3020 * Cookbook: add the *top-priority-values* and *unload-firstly-loaded* recipes.
3021 * Install: add ``gcc`` to the build requirements in RPM specfile.
3022 * Silent any prereq violation warning message when processing *Dependent
3023 Reload* mechanism or ``purge`` sub-command.
3024 * Doc: mention ``createmodule.sh`` and ``createmodule.py`` scripts in FAQ.
3025 (fix issue#189)
3026 * Register all alternative names of loaded modules in environment with
3027 ``MODULES_LMALTNAME`` variable. These names correspond to the symbolic
3028 versions and aliases resolving to the loaded modules. Helps to consistently
3029 solve ``conflict`` or ``prereq`` constraints set over these alternative
3030 names. (fix issue#143 / see
3031 :ref:`v42-consistency-module-load-unload-commands` section in MIGRATING
3032 document)
3033 * Doc: describe ``MODULES_LMALTNAME`` in module.1 man page.
3034 * Install: add ``--with-bin-search-path`` configure option to get in control
3035 of the path list used to search the tools required to build and configure
3036 Modules. (fix issue#164)
3037 * Install: add ``--enable-silent-shell-debug-support`` configure option to add
3038 the ability to control whether or not code to support silent shell debug
3039 should be added to the module function and sh-kind initialization scripts.
3040 (fix issue#166)
3041 * Install: add ``--enable-quarantine-support`` configure option to add the
3042 ability to control whether or not code to support quarantine mechanism
3043 should be added to the module function and initialization scripts.
3044 (fix issue#167)
3045 * Check version set in modulefile magic cookie. If modulefile sets a version
3046 number greater than ``modulecmd.tcl`` script version, this modulefile is not
3047 evaluated like when no magic cookie is set at all. (fix issue#171 / see
3048 :ref:`v42-versioned-magic-cookie` section in MIGRATING document)
3049 * Fix uninitialized variable in procedure producing list of element output.
3050 (fix issue#195)
3051 * Ensure the consistency of ``module load`` modulefile command once the
3052 modulefile defining it has been loaded by assimilating this command to a
3053 ``prereq`` command. Thus the defined constraint is recorded in the
3054 ``MODULES_LMPREREQ`` environment variable. Same approach is used for
3055 ``module unload`` modulefile command which is assimilated to a ``conflict``
3056 command. Thus the defined constraint is recorded in the
3057 ``MODULES_LMCONFLICT`` environment variable. (see
3058 :ref:`v42-alias-symbolic-name-consistency` section in MIGRATING document)
3059 * Only look at loaded modules when unloading so unloading an nonexistent
3060 modulefile does not produce an error anymore. (fix issue#199)
3061 * Report error raised from modulefile evaluation as ``ERROR`` rather
3062 ``WARNING``, like when a conflict constraint is hit. Moreover this kind of
3063 evaluation error is now silenced on global evaluation like when processing
3064 ``avail`` or ``search`` sub-commands.
3065 * Record messages to report them by block on when processing a ``load`` or an
3066 ``unload`` modulefile evaluation to improve readability on these evaluating
3067 modes that may cascade additional actions. (see
3068 :ref:`v42-module-message-report` section in MIGRATING document)
3069 * Foreground ``load``, ``unload``, ``switch`` and ``restore`` actions (i.e.,
3070 asked on the command-line) now report a summary of the additional load and
3071 unload evaluations that were eventually triggered in the process.
3072 * Support ``del`` and ``remove`` aliases for ``unload`` sub-command like on
3073 compatibility version. (fix issue#200 with contribution from Wenzler)
3074 * Correctly transmit the arguments along with the command to execute on
3075 ``system`` modulefile command. (fix issue#201)
3076 * Contrib: add ``mt`` utility script which helps to run just specific part of
3077 the test suite.
3078 * Introduce ``set-function`` and ``unset-function`` modulefile commands to
3079 define shell function on sh-kind and fish shells. (fix issue#193 with
3080 contribution from Ben Bowers)
3081
3082
3083 .. _4.1 release notes:
3084
3085 Modules 4.1.4 (2018-08-20)
3086 --------------------------
3087
3088 * Doc: fix typo on ``getenv`` command description in modulefile(5) man page
3089 and clarify this command should be preferred over ``::env`` variable to
3090 query environment variable value in modulefile.
3091 * Init: fix ``bash`` and ``zsh`` completion scripts to enable Extended Regular
3092 Expression (ERE) on ``sed`` command with ``-E`` argument (rather ``-r``) for
3093 compatibility with OS X's and BSDs' sed. (fix issue#178)
3094 * Handle default version sets on an hidden modulefile (were not found
3095 previously). (fix issue#177)
3096 * Init: fix ``ksh`` initialization script for ksh88 compatibility. (fix
3097 issue#159)
3098 * Install: use ``sed`` command rather ``grep`` and ``cut`` in ``configure``
3099 and ``Makefile`` scripts. (fix issue#175 with contribution from Michael
3100 Sternberg)
3101 * Fix typo, tab indentation and pipe opening mode on ``createmodule.py``
3102 utility script. (contribution from Jan Synacek)
3103 * Check ``ModulesVersion`` value set from ``.version`` rc file to ensure this
3104 value refers to a version name in current directory. Report error if a
3105 nested value is detected and ignore this value. (fix issue#176)
3106
3107
3108 Modules 4.1.3 (2018-06-18)
3109 --------------------------
3110
3111 * Make ``setenv`` command alter ``env`` Tcl global array during ``help``,
3112 ``test`` or ``whatis`` evaluation modes. (fix issue#160)
3113 * Doc: describe MANPATH variable special treatment on compatibility version
3114 in diff_v3_v4 document.
3115 * Initialize and export _moduleraw SH shell function if ``stderr`` is attached
3116 to a terminal. Was previously checking ``stdout``. (fix issue#169)
3117 * For ``csh`` shells, quote code generated by modulecmd.tcl to pass it to the
3118 ``eval`` shell command.
3119 * Escape special characters when producing code to define shell aliases (fix
3120 issue#165)
3121 * Correct modulefile lookup when a modulefile directory is overwritten by a
3122 module alias definition but it contains an empty sub-directory. (fix
3123 issue#170)
3124 * Doc: describe ``getenv`` command in modulefile(5) man page.
3125 * Improve SH shell detection in profile.sh initialization script to use shell
3126 variable on ``bash`` or ``zsh`` to determine current shell name. (fix
3127 issue#173)
3128
3129
3130 Modules 4.1.2 (2018-03-31)
3131 --------------------------
3132
3133 * Add an example global rc file in ``contrib/etc`` directory that ensures
3134 ``MODULEPATH`` is always defined.
3135 * Check ``HOME`` environment variable is defined on ``savelist`` and
3136 ``is-saved`` commands or raise error if not.
3137 * Fix saving of deep module default version in collection when version pinning
3138 is disabled: if ``foo/bar/version`` is default version for ``foo``,
3139 collection will retain just ``foo`` (was retaining ``foo/bar``).
3140 * Enable to save and restore collections containing full path modulefiles
3141 eventually with no modulepath defined.
3142 * Run ``puts`` command not related to ``stderr`` or ``stdout`` channels in
3143 calling modulefile context to correctly get access to the targeted file
3144 channel. (fix issue#157)
3145 * Quote ``autoinit`` result for eval interpretation on SH-kind shells to avoid
3146 parameter expansion to randomly occur on generated code depending on file
3147 or directory names of current working directory. (fix RH bug#1549664)
3148 * Ignore empty elements found in ``MODULEPATH``, ``LOADEDMODULES`` or
3149 ``_LMFILES_`` to ensure all elements in these variables are non-empty
3150 strings.
3151 * Raise error if loaded environment is in an inconsistent state when calling
3152 commands requiring correlation of information from the ``LOADEDMODULES`` and
3153 the ``_LMFILES_`` environment variables. Error raised on ``load``,
3154 ``unload``, ``switch``, ``reload``, ``purge``, ``list``, ``save`` and
3155 ``restore`` commands. May affect ``info-loaded`` or ``is-loaded`` commands
3156 if module passed as argument to these command is specified as a full path
3157 modulefile.
3158 * Fix ``list`` command to process loaded modules information before performing
3159 any content output.
3160 * Install: adapt ``configure`` script and Makefiles to support installation on
3161 Cygwin system.
3162 * Detect terminal width on Windows ``cmd`` terminal with ``mode`` command.
3163 * Improve Windows ``cmd`` shell support: error code returned, echoing text,
3164 shell alias creation and removal, working directory change.
3165 * Raise error when an empty module name is passed to module sub-commands like
3166 ``load``, ``display`` or ``unload``.
3167 * Raise error when an empty collection name is passed to module sub-commands
3168 like ``save``, ``saveshow`` or ``restore``.
3169 * Raise error when an empty path is passed to module ``unuse`` sub-command,
3170 like already done on ``use`` sub-command.
3171 * Clear argument list if an empty module command name is passed.
3172 * Fix ``module`` function definition for all shells in ``autoinit`` command to
3173 correctly handle empty-string parameters or parameters containing
3174 white-spaces, quotes, escape characters.
3175 * Fix ``module`` function definition for Python to accept being called with no
3176 argument.
3177 * Fix parameter expansion on ``module`` function for all SH-kind shells when
3178 quarantine mode is activated.
3179 * Escape ``\`` character when producing R shell code.
3180
3181
3182 Modules 4.1.1 (2018-02-17)
3183 --------------------------
3184
3185 * Make separator lines, used on ``display`` command result for instance, fit
3186 small screen width.
3187 * Install: give ability to build and install Modules from git repository
3188 without documentation if ``sphinx-build`` cannot be found.
3189 * Install: adapt ``configure`` script and Makefiles to support installation on
3190 FreeBSD, Solaris and OS X systems. (fix issue#147)
3191 * Rework code generated by ``autoinit`` for sh-kind shells to avoid use of
3192 local variables as those are defined differently through the sh variants.
3193 (also fix issue#147)
3194 * Init: use a default value on undefined variables in sh-kind scripts to avoid
3195 unbound variables in bash ``-eu`` mode. (fix issue#151)
3196 * Correctly detect terminal column number on Solaris.
3197 * Init: fix csh init script to get compatibility with pure csh shell
3198 * Sanitize content of ``MODULEPATH`` before using it at run-time, to make
3199 potential relative paths absolute, remove trailing slashes, etc. (fix
3200 issue#152)
3201 * Check loaded modulefiles still exists before displaying statistics on them
3202 during a ``list`` action.
3203 * Use a specific reference counter variable name (``MODULES_MODSHARE_<VAR>``
3204 instead of ``<VAR>_modshare``) for DYLD-specific variables. (fix issue#153)
3205 * No error raise when updating a DYLD or LD path-like variable on OS X when
3206 System Integrity Protection (SIP) is enabled. In this situation, these
3207 variables are not exported in subshell context, so they appear undefined.
3208 * Init: protect arguments passed to the ``_moduleraw`` sh function from
3209 interfering content of current working directory. (fix issue#154)
3210 * Install: move ``hostname`` RPM requirement to the compat sub-package.
3211 * Start pager process only if some text has to be printed. (partially fix
3212 issue#146)
3213 * Ignore ``PAGER`` environment variable to configure Modules pager to avoid
3214 side effects coming from a general pager configuration not compatible with
3215 Modules pager handling. (fix issue#146)
3216 * Do not blank anymore default Modules pager options if default pager is
3217 ``less`` when the ``LESS`` environment variable is defined. (fix issue#146)
3218
3219 .. warning:: With this bugfix release, changes have been made on the pager
3220 setup to avoid side effects coming from the system general pager
3221 configuration. As a result ``PAGER`` environment variable is now ignored
3222 and ``MODULES_PAGER`` should be used instead to adapt Modules pager
3223 configuration at run-time.
3224
3225
3226 Modules 4.1.0 (2018-01-15)
3227 --------------------------
3228
3229 * Extend stderr output redirection on sh-kind shells to all terminal-attached
3230 shell session, not only interactive shell session.
3231 * Extend shell code produced by the ``autoinit`` command to perform the same
3232 environment initialization as done in ``init`` shell scripts (default value
3233 set for module-specific environment variables, parse or source of
3234 configuration files).
3235 * Make init shell scripts rely on ``autoinit`` command to define the
3236 ``module`` command and setup its default environment.
3237 * Fix error rendering code for Tcl shell by producing a call to the ``error``
3238 procedure.
3239 * Introduce pager support to handle informational messages, using ``less``
3240 command with ``-eFKRX`` options by default. Environment variable
3241 ``MODULES_PAGER`` or ``PAGER`` may be used to supersede default pager
3242 command and options. ``--paginate`` and ``--no-pager`` switches enable or
3243 disable pager from the command line.
3244 * Install: add ``--with-pager`` and ``--with-pager-opts`` configure options to
3245 define default pager command and its relative command-line options.
3246 * Introduce quarantine mechanism to protect module execution against side
3247 effect coming from the current environment definition. Variables whose name
3248 has been put in ``MODULES_RUN_QUARANTINE`` will be emptied or set to the
3249 value hold by ``MODULES_RUNENV_<VAR>`` in the modulecmd.tcl run-time
3250 environment. Quarantine variable original value is then restored within
3251 modulecmd.tcl execution context once it has started.
3252 * Install: add ``--with-quarantine-vars`` configure option to define at build
3253 time the ``MODULES_RUN_QUARANTINE`` and ``MODULES_RUNENV_<VAR>`` environment
3254 variables set in initialization scripts.
3255 * Add ``MODULES_SILENT_SHELL_DEBUG`` environment variable to disable on sh
3256 shell and derivatives any ``xtrace`` or ``verbose`` debugging property for
3257 the duration of either the module command or the module shell initialization
3258 script. (fix issue#121)
3259 * Change error code produced by modulecmd.tcl for the Tcl, Perl, Python, Ruby,
3260 CMake and R scripting languages to return a 'false' boolean value in case of
3261 error rather raising a fatal exception.
3262 * Adapt module function definition for Tcl, Perl, Python, Ruby, CMake and R
3263 scripting languages to always return a value, result of the modulecmd.tcl
3264 run. When modulecmd.tcl run does not produce a specific status, a 'true'
3265 boolean value is returned. On CMake, resulting value is returned though a
3266 ``module_result`` global variable.
3267 * Spool content sent to the stdout channel with ``puts`` command during a
3268 modulefile interpretation, to effectively transmit this content to stdout
3269 after rendering the environment changes made by this modulefile. (fix
3270 issue#113)
3271 * Introduce ``append-path``, ``prepend-path``, ``remove-path`` and
3272 ``is-loaded`` module sub-commands, based on existing modulefile-specific
3273 Tcl commands. (fix issue#116)
3274 * Introduce ``is-saved``, ``is-used`` and ``is-avail`` modulefile Tcl commands
3275 and module sub-commands to test availability of collection, modulepath or
3276 modulefile.
3277 * Raise error when a call to ``path`` or ``paths`` module sub-commands is
3278 attempted during a modulefile interpretation. Both commands now return text
3279 rather print text on scripting languages. An empty string is returned in
3280 no match case instead of a false boolean value.
3281 * Introduce ``module-info loaded`` modulefile command and its module
3282 sub-command counterpart ``info-loaded``. This new command returns name of
3283 the modules currently loaded corresponding to the name passed as argument.
3284 (fix issue#3)
3285 * Fix ``is-loaded`` command to correctly handle multiple module names passed
3286 as argument (fix issue#138)
3287 * Support no argument on ``is-loaded``, ``is-saved`` and ``is-used`` commands
3288 to return if anything is respectively loaded, saved or used.
3289 * Interpret ``module source`` command set in modulefile in ``unload`` mode
3290 when the modulefile itself is interpreted in this mode.
3291 * Consider a modulefile passed with name starting by ``./`` or ``../`` a full
3292 path name modulefile, like those starting by ``/``. These kind of names are
3293 converted to absolute path names, for instance to register them in loaded
3294 modulefile list during a ``load`` command.
3295 * Correlate modulefile passed as full path name (starting by either ``./``,
3296 ``../`` or ``/``) to already loaded modulefile registered with regular
3297 module name (file name without its modulepath prefix) to prevent for
3298 instance from loading twice same modulefile. Correlate in the same way
3299 regular module name to already loaded full path name modulefile.
3300 * Introduce ``MODULES_COLLECTION_PIN_VERSION`` environment variable to record
3301 modulefile version number when saving collections even if version
3302 corresponds to the default one. (fix issue#89)
3303 * Fix location of ``etc/rc`` global RC file to ``@prefix@/etc/rc`` instead of
3304 ``$MODULESHOME/etc/rc`` not to depend on ``MODULESHOME`` environment
3305 variable value.
3306 * Strengthen argument check for ``append-path``, ``prepend-path`` and
3307 ``remove-path`` modulefile Tcl commands and module sub-commands. Raise error
3308 if argument list is not correct.
3309 * Fix support for the ``--delim=C`` argument form on ``append-path``,
3310 ``prepend-path`` and ``remove-path`` commands.
3311 * Fix path reference counter handling in case path element is an empty string.
3312 Distinguish an empty path element from a variable set empty to clear it.
3313 * Pass multiple path elements separated by delimiter character as one string
3314 on ``append-path``, ``prepend-path`` and ``remove-path`` commands.
3315 * Accept multiple path element arguments on ``append-path``, ``prepend-path``
3316 and ``remove-path`` commands.
3317 * Introduce the ``--duplicates`` argument option to ``append-path`` and
3318 ``prepend-path`` commands to add a path element already registered in
3319 variable.
3320 * Introduce the ``--index`` argument option to ``remove-path`` command to
3321 delete a path entry by passing its position index in variable.
3322 * Provide the ability to setup a site-specific configuration sourced at the
3323 start of ``modulecmd.tcl`` main procedure. This configuration is a Tcl
3324 script named ``siteconfig.tcl`` which enables to supersede any Tcl
3325 definition made in ``modulecmd.tcl``. Location of this file is controlled
3326 at configure time with the ``--etcdir`` option.
3327 * Add the ability to handle paths containing reference to environment variable
3328 in ``MODULEPATH``. When these kind of paths are used by ``module`` command,
3329 the variable references are converted to their corresponding value or to an
3330 empty string if they are not defined.
3331 * Enclose value set to environment variable on Tcl within curly braces rather
3332 double quotes to protect special characters in it from interpretation.
3333 * Correctly parse ``.modulespath`` initialization file to handle lines without
3334 any ``#`` character or to handle files with no content to extract.
3335 * Re-introduce the ``--enable-versioning`` configure option, which appends
3336 Modules version to installation prefix and deploy a ``versions`` modulepath
3337 shared between all versioning enabled Modules installation. A modulefile
3338 corresponding to Modules version is added to the shared modulepath and
3339 enables to switch from one Modules version to another.
3340 * Fix removal of CMake generated temporary script file by stripping newline
3341 character from script file name.
3342 * Add ``MODULES_CMD`` environment variable to expose path to the currently
3343 active module command script. This variable is set at initialization time.
3344 * Introduce ``modulecmd`` wrapper script, installed in binary directory, which
3345 executes the active module command.
3346 * Fix modulefile Tcl interpreter reset when handling list variables. (fix
3347 issue#145)
3348 * Introduce 'module-virtual' modulefile Tcl command to associate a virtual
3349 module name to a modulefile. This module can be located with its virtual
3350 name and the associated modulefile is the script interpreted when loading,
3351 unloading, etc.
3352 * Resolution of relative paths occurring during a modulefile interpretation to
3353 target a modulefile or a modulepath now takes the directory of the currently
3354 interpreted modulefile as the current working directory to solve the
3355 relative paths.
3356
3357
3358 .. _4.0 release notes:
3359
3360 Modules 4.0.0 (2017-10-16)
3361 --------------------------
3362
3363 Starting with this release, modules-tcl has become Modules. The following
3364 changes describe the differences with last modules-tcl release (1.923). To
3365 learn about the changes between this release and last Modules 3.2 release,
3366 please see the :ref:`MIGRATING` document.
3367
3368 * Relax constraint on command-line argument position so options and
3369 switches can be passed either before or after command name.
3370 * Report ``unsupported option`` warning rather stop on error when
3371 compatibility-version specific command-line switches are passed (
3372 ``--force``, ``--human``, ``--verbose``, ``--silent``, ``--create``,
3373 ``--icase``, ``--userlvl``).
3374 * Keep empty ``module load`` line in shell configuration files after running
3375 the ``initrm`` or ``initclear`` commands.
3376 * Always return the value of ``tcl_platform(osVersion)`` for ``uname release``
3377 * Optimize code output, for Perl to only return ``1;`` once for a no-operation
3378 situation and for Python to not ``import os`` when there is only an error
3379 to render.
3380 * Use value of system command ``uname -n`` for ``uname nodename``.
3381 * Add support for CMake *shell*
3382 * Ignore ``/`` character used as suffix in modulefile name passed on command
3383 line.
3384 * Rename Perl initialization script in ``perl.pm`` and Python in
3385 ``python.py``.
3386 * Add support for Ruby *shell* (with contribution from Tammo Tjarks)
3387 * Add support for R *shell* (with contribution from Roy Storey)
3388 * When a *default* is set for a given module name, target modulefile can
3389 be referred on as *modulename/default* in addition to just *modulename*.
3390 * Locate symbolic versions on ``avail`` command even these symbols are set
3391 over a module alias or another symbolic version. In this situation the
3392 symbol spread along the resolution path until reaching a modulefile.
3393 * Define a more standard shebang on modulecmd.tcl script.
3394 * Determine modulefile corresponding to given module name using the loaded
3395 context only on ``unload`` situation.
3396 * Enable to unload *mod/dir/subdir/vers* when unload of *mod* or *mod/dir*
3397 asked. Was previously working only if deep module to unload was also the
3398 default version for these root names.
3399 * Make -l/-t switches mutually exclusive. Last switch mentioned on the
3400 command-line is honored.
3401 * Output parsable modulepath header when -l/-t switches are enabled.
3402 * When searching for a module in a given modulepath directory, if a module
3403 alias or a symbolic version matches searched module but the target of
3404 this alias or symbol is not found in current modulepath directory,
3405 search for this target restarting search from the first modulepath in
3406 list to ensure modulepath priority.
3407 * Solve aliases or symbolic versions looking for all modulepaths on ``search``
3408 and ``paths`` commands. Was previously solved if their target was found in
3409 same modulepath directory.
3410 * Add support for hidden *dot* modulefiles. A hidden modulefile does not
3411 appear in case of wild search, it is only returned when search is about
3412 its exact name.
3413 * No table header print in --long mode on an ``avail`` command if no result
3414 are returned.
3415 * Add blank line between displayed list of elements, for instance between
3416 modulepath content on ``avail`` command.
3417 * Improve readability of error messages encountered during modulefile
3418 execution by putting Tcl error message first after the ``Module ERROR``
3419 prefix.
3420 * Do not exit immediately when an internal error occurs in currently
3421 interpreted modulefile. Consider this interpretation as failed and
3422 continue to proceed the other modulefile arguments.
3423 * When multiple modulefiles are passed on ``display``, ``help`` and ``test``
3424 commands only output one separator line between 2 interpreted modulefiles.
3425 * Fix environment settings stack handling issue when restoring stack after
3426 a failed attempt to load a modulefile in a modulefile.
3427 * Failed attempt to load or unload a modulefile within a modulefile now
3428 leads to this upper modulefile load or unload failure. Previously upper
3429 modulefile were loaded respectively unloaded even if its dependent
3430 sub-modulefile failed to load or unload.
3431 * During a ``switch`` command, if the unloading part fails the loading part
3432 will not be tried. Unloading part fails if module to unload does not
3433 exist or its unload interpretation raise error.
3434 * Init: use ``module source`` rather shell command ``source`` to load modulerc
3435 system configuration in sh-kind, csh-kind and fish shell init scripts.
3436 * Install: transform configuration options to bind to an existing
3437 compatibility Modules version into option (--enable-compat-version) to
3438 build and install this compatibility version along with main version.
3439 * Init: adapt initialization scripts to handle both main and compatibility
3440 version. By default a shell script enables main version and if the
3441 environment variable MODULES_USE_COMPAT_VERSION is set to 1, the
3442 compatibility version is enabled instead of main version.
3443 * Install: import from compatibility version and install ``add.modules``
3444 and ``mkroot`` utility scripts (scripts developed by R.K. Owen).
3445 * Install: update RPM spec file to handle compatibility version as a
3446 ``compat`` sub-package.
3447 * Add completion script for Fish shell (contribution from BEFH).
3448 * Doc: extend content of diff_v3_v4 to details all noticeable changes
3449 between v3.2 and v4.0.
3450 * Doc: introduce MIGRATING guide to learn the major changes when moving
3451 from v3.2 to v4.0.
3452 * Fix ``list`` command when full pathname modulefile is loaded (fix bug#132)
3453 * Install: handle version number though git tags in scripts, documentation
3454 and RPM spec file.
3455 * Doc: migrate documents from POD format to reStructuredText to benefit from
3456 Sphinx documentation framework and Read The Docs publishing capabilities.
3457
3458 Above changes describe the differences with modules-tcl release 1.923. To
3459 learn about the changes between Modules 4.0 and last Modules 3.2 release,
3460 please see the :ref:`MIGRATING` document.
3461
3462
3463 modules-tcl-1.923 (2017-07-20)
3464 ------------------------------
3465
3466 * Fix ``aliases`` command when a global or user RC file is set.
3467 * Find and solve global or user RC aliases and symbolic versions on
3468 ``search``, ``whatis`` and ``paths`` commands.
3469 * Do not look at currently loaded modules to resolve the target of a module
3470 alias.
3471 * Rework default and latest versions search on ``avail`` command. Correct
3472 display when at a given level a sub-directory element is last element in
3473 directory among modulefiles. Previously sub-directory was printed but
3474 last file among modulefiles was also printed (2 latest versions at the
3475 same level). A directory tagged "default" does not appear anymore in
3476 default listing result as its content (the default version found in that
3477 directory) will be displayed.
3478 * When an alias is set and overrides name of an existing directory, take
3479 this alias into account for default and latest choice and ignore
3480 directory content.
3481 * Bad default set will lead to no result displayed for the corresponding
3482 module in case of default ``avail`` display.
3483 * Correct inclusion of aliases in output result when these aliases are not
3484 part of the exact same module path than module path of the search.
3485 * Rewrite existing shell initialization file with initadd, initprepend,
3486 initswitch, initrm and initclear commands rather than writing a new
3487 file then copying this new file to replace the existing initialization
3488 file. In addition only re-writes shell initialization file if its content
3489 need to be altered.
3490 * Raise an error on initadd, initprepend, initswitch, initrm and initclear
3491 commands when no ``module load`` line are found in shell initialization
3492 file.
3493 * Normalize error messages for the various collection-related commands
3494 when collection cannot be accessed.
3495 * Cleanup existing reference counters of a path list variable when this
3496 variable is altered by a ``setenv`` or an ``unsetenv`` command.
3497 * Init: do not pollute tab-completion with moduleraw command. (Bert Wesarg)
3498 * Make use of the same Tcl interp for each modulefile interpretation and
3499 use another one for each modulerc (but the same for each modulerc). By
3500 doing so we proceed like on C-version where same interpreter is used
3501 across modulefile or modulerc interpretation. Huge performance
3502 improvement is achieved with this change on commands making intensive
3503 use of interp like ``avail``. Interpreter state is reset from one
3504 interpretation to another: the initial variable and procedure state is
3505 restored before each new interpretation to avoid spread of definitions
3506 from one interpretation to another. Also in case of nested interpretation
3507 each interpretation level has its own interpreter so a module loaded by
3508 another does not influence the interpretation of the module loading it.
3509 * Improve performance of aliases and symbolic versions resolution by
3510 computing these resolution at definition time. As a consequence
3511 resolution loop are not registered anymore and produce an error message
3512 when spotted not at display time.
3513 * Reduce number of ``access`` system call by trying access to modulefile
3514 when reading the content of a modulefile directory rather testing access
3515 before trying it.
3516 * No error raise on empty argument list for load. To cope with initadd
3517 behavior that requires at least an empty ``module load`` line in startup
3518 files. (fix SF bug#88)
3519 * Fix initadd to handle load line without trailing space. Was previously
3520 expecting load directive to be written "module load " to get a match. With
3521 fix, ``module load`` line will also be matched.
3522 * Like C-version catch raised error when break or continue are called from
3523 outside of a loop to handle them as when they are called from modulefile
3524 main body. (fix SF bug#87)
3525 * Return error on ``module use`` command when an empty path string is
3526 provided rather ignoring it.
3527 * Workaround ``min`` and ``max`` functions and ``lreverse`` procedure for
3528 correct operations under Tcl version 8.4.
3529 * Install: add --with-tclsh configure option to give the ability to choose
3530 the Tcl interpreter shell to setup in initialization scripts.
3531 * Handle error raised from the ModulesDisplay, ModulesHelp and ModulesTest
3532 procedures in the same way than for the evaluation of the modulefile
3533 content. An error occurring during the evaluation of the modulefile
3534 content will lead to no evaluation of the ``display``, ``help`` and
3535 ``test`` command specific functions.
3536 * Remove ``debug`` module command
3537 * Doc: describe ``path``, ``paths`` and ``autoinit`` module command.
3538 * Correct use of xrdb tool when not installed in default path.
3539 * Fix ``init*`` module commands to behave more like C-version and document
3540 remaining differences in diff_with_c-version.
3541 * Init: make ``sh`` init script closer to POSIX specification to support sh
3542 flavors different than Bash or Zsh like Dash.
3543 * Fix column-mode display for very short width terminal.
3544 * Install: introduce an ``install`` non-regression testsuite which is
3545 triggered by the ``make testinstall`` command and checks modules-tcl
3546 installation is operational.
3547 * Init: fix modulerc load test on ``fish`` init script.
3548 * Init: fix interactive shell test on ``sh`` init script.
3549 * Install: add --enable-example-modulefiles configure option that install
3550 by default some modulefiles provided as example in the system modulefiles
3551 directory.
3552 * Install: when uninstalling, do not remove modulefiles directory if it is
3553 not empty.
3554 * Add completion script for Zsh shell.
3555 * Add ``module test`` command to trigger when called execution of a
3556 ModulesTest procedure in target modulefile following same kind of
3557 mechanism than ``module help``.
3558
3559
3560 modules-tcl-1.832 (2017-04-29)
3561 ------------------------------
3562
3563 * Fix ``getenv`` sub-command to correctly return environment variable value.
3564 * Clarify in man-pages display of module alias and symbolic version-name on
3565 ``avail`` command and management of file access issue when locating
3566 modulefiles.
3567 * Distinguish access issue (permission denied) from find issue (cannot
3568 locate) when trying to access directly a directory or a modulefile as
3569 done on ``load``, ``display`` or ``whatis`` commands. In addition on this
3570 kind of access, not readable .modulerc files are ignored rather producing a
3571 missing magic cookie error.
3572 * When mode is set to unload, ``module load`` commands in modulefile are
3573 interpreted as ``module unload`` commands. To guaranty correct behavior
3574 regarding requirements, the module list passed to the load command is
3575 reversed to unload the modulefiles in the reverse order than they have
3576 been loaded.
3577 * Correct ``display`` command to only report module commands set in
3578 modulefile and not those set in the various .modulerc on the path toward
3579 this modulefile.
3580 * Fix bash and tcsh completion scripts to eliminate symbolic version names
3581 from ``avail`` command result.
3582 * Improve ``avail`` command when a symbolic version-name is passed as
3583 argument to return the modulefile target of this symbolic version-name.
3584 * When looking for an implicit default in a directory, now a module alias is
3585 taken into account so it can be returned as the last element in it
3586 (highest numerically sorted version).
3587 * Fix ``list`` command to correctly display the ``default`` tag along loaded
3588 modules when set via a .version file.
3589 * Fix long output of ``list`` command to display the symbolic version-names
3590 associated to each loaded module if any.
3591 * Improve ``avail`` command to return alias module when an alias name is
3592 passed as argument.
3593 * On a ``--default`` listing, a modulefile does not appear anymore if a
3594 directory is set default at the same level. On a ``--latest`` listing, a
3595 directory does not appear anymore if set default but not the latest.
3596 * Read modulerc and validate its header in a single open/read/close sequence
3597 instead of two in order to reduce to number of IO operations during an
3598 ``avail`` command.
3599 * Drastically reduce grid size computation time which removes overhead when
3600 displaying module avail results in column-mode.
3601 * Translate module name to currently interpreted module name when name
3602 correspond to the last part this interpreted module only in case of
3603 symbolic version-name or alias resolution.
3604 * Avoid resetting regular path (/usr/bin) or manpath (/usr/share/man) when
3605 switching from Tcl to C version in switchml utility.
3606 * Raise error on x-resource if DISPLAY environment variable is not set.
3607 * Fix lisp init script which was broken for environment change actions.
3608
3609
3610 modules-tcl-1.775 (2017-03-07)
3611 ------------------------------
3612
3613 * Improve README with examples, requirements, links, etc. Also update
3614 INSTALL documentation with details on the new configure/make/make install
3615 process.
3616 * Add display of a release date next to the version number when calling for
3617 ``--help`` or ``--version``.
3618 * Update diff_with_c-version document to describe the features of the
3619 Tcl-version that are not supported on the C-version. Also state that the
3620 diff takes C version 3.2.10 against Tcl version 1.729 as a basis.
3621 * Introduce ``switchml`` tool, a shell function (or alias for csh or tcsh
3622 shells) that swap currently enabled Modules version (C or Tcl) by the
3623 other version (C or Tcl). Configure option ``--with-cver-initdir`` must be
3624 defined to enable ``switchml`` in initialization script.
3625 * Define a PATH and MANPATH in shell initialization scripts that point to
3626 the defined modules-tcl installation directories.
3627 * Give ability to generate distribution tarball from the git repository with
3628 Makefile ``dist`` target.
3629 * Introduce an installation process for this software following the
3630 configure/make/make install fashion. Configure step enables to choose
3631 installation paths and init scripts features to activate. Make step mainly
3632 translates init scripts with the configuration set. Make install creates
3633 target directories and copy files into them.
3634 * Fix MODULESHOME setup in autoinit command to define it as an absolute path
3635 and set it to the upper directory when modulecmd.tcl is located in a ``bin``
3636 or a ``libexec`` directory.
3637 * Correct alias and version resolution on avail command which was erroneous
3638 in case of a modulefile holding symbols (like ``default``) and targeted by
3639 aliases. Avail output was showing the aliases holding the symbols instead
3640 of the modulefile.
3641
3642
3643 modules-tcl-1.729 (2017-02-01)
3644 ------------------------------
3645
3646 * Add documentation in module(1) man page on the modulefile collection
3647 concept and the relative ``save``, ``restore``, ``saverm``, ``saveshow``
3648 and ``savelist`` commands.
3649 * Add document to list the differences of the functionalities that can be
3650 found on the C-version of the Modules package compared to the
3651 Tcl-version.
3652 * Improve modulecmd.tcl shebang to only search ``tclsh`` once if found in
3653 PATH.
3654 * Add ``module-info mode`` check against ``remove`` and ``switch`` values.
3655 * Introduce ``module-info command`` Modules-specific Tcl command to
3656 distinguish complex ``load`` or ``unload`` commands that cannot be
3657 determined with ``module-info mode`` alone. For instance a modulefile can
3658 now be aware that a ``switch``, a ``restore`` or a ``purge`` command is
3659 currently being run.
3660 * Enable usage of ``module-info`` Modules-specific Tcl command from a
3661 modulerc file.
3662 * Fix ``module-info specified`` Modules-specific Tcl command.
3663 * No exit raise on modulefile or modulerc error during ``avail``, ``aliases``,
3664 ``whatis`` and ``search`` commands to avoid harming results from these
3665 global commands if error exists in a few modulefiles.
3666 * Exit with error code when a critical error is encountered when
3667 interpreting a modulefile or a modulerc.
3668 * Inhibit non-critical error report raised from modulefiles during ``avail``,
3669 ``aliases``, ``whatis`` and ``search`` commands to avoid error flood when
3670 parsing all modulefiles or modulercs.
3671 * Handle multiple lines of ``module-whatis`` Modules-specific Tcl commands
3672 defined for the same modulefile.
3673 * Handle multiple arguments passed to the ``module-whatis`` Modules-specific
3674 Tcl commands. They are joined to get a single line of text.
3675 * Return error on ``whatis`` command if searched modulefile is not found.
3676
3677
3678 modules-tcl-1.704 (2017-01-20)
3679 ------------------------------
3680
3681 * Set path variable counter to 1 for paths without a known reference count
3682 (was previously set to 999999999).
3683 * Introduce ``envml`` utility which acts as an application launcher where
3684 module commands are instantiated to setup environment before launching
3685 the given application.
3686 * Always register paths provided to be part of MODULEPATH environment
3687 variable as absolute paths to get independent from the current working
3688 directory.
3689 * Inhibit next modulefiles interpretation with ``exit`` Modules-specific Tcl
3690 command only if current mode is ``load``.
3691 * Add argument to ``module-info shell`` and ``module-info shelltype`` to test
3692 current shell or shelltype value.
3693 * Fix use of ``default`` version-name to not consider it as a module symbol
3694 if a modulefile is named ``default``.
3695 * Fix path variable counters when ``:`` character is used in elements of a
3696 path-like variable.
3697 * Update module(1) and modulefile(5) man pages to clear content specific to
3698 the C version of Modules and add content specific to or adapt content that
3699 behave differently on this Tcl version.
3700 * Fix TCLSH variable issue in Python init script.
3701
3702
3703 modules-tcl-1.677 (2017-01-04)
3704 ------------------------------
3705
3706 * Make ``switch`` command handle a single argument. The modulefile to switch
3707 to is the one passed on the command-line and the modulefile to unload is
3708 assumed to be the currently loaded module with the same root name as
3709 this modulefile specified on the command-line.
3710 * Make ``switch`` command idempotent by always ending up with ``old`` unloaded
3711 and ``new`` loaded, whatever the starting situation is.
3712 * Fix ``exit`` Modules-specific Tcl command.
3713 * Add ``refresh`` command as alias on ``reload`` command.
3714 * Add dummy ``module-log``, ``module-trace``, ``module-user`` and
3715 ``module-verbosity`` Modules-specific Tcl commands to enable support for
3716 modulefiles using them.
3717 * Fix ``system`` Modules-specific Tcl command to behave like described on the
3718 man page.
3719 * Fix ``module list`` when module loaded with full path
3720 * Disable ``g_force`` property by default to avoid loading a modulefile
3721 already loaded. It also avoids path element reference counting to get
3722 increased when the same module is asked twice for load.
3723 * Clarify module-info ``mode`` option and set ``help`` mode on ``module help``
3724 command.
3725 * Clarify module-info ``flags`` and ``user`` options.
3726 * Handle empty or separator path on ``add-path`` ad ``unload-path`` commands.
3727 * Delete environment variable targeted by an ``unsetenv`` command on
3728 ``unload`` mode if no value has been provided along. On display mode, print
3729 environment variable value if any has been passed to ``unsetenv`` command.
3730 * When setting Tcl variable, enclose value within double quotes.
3731 * Fix perl quoting style for variable set, escape single quotes rather
3732 double quotes.
3733 * Call ``unuse`` command instead of ``use`` command on a ``module unload``.
3734 * Fix ``continue`` Modules-specific Tcl command.
3735 * Add ``chdir`` Modules-specific Tcl command.
3736 * Fix ``break`` Modules-specific Tcl command.
3737
3738
3739 modules-tcl-1.655 (2016-11-23)
3740 ------------------------------
3741
3742 * No display of modulepath header if no module found in it.
3743 * Remove call to ``module aliases`` on ``module avail`` command, as aliases
3744 are now directly included in the ``avail`` results.
3745 * Include module aliases in the displayed result of an ``avail`` command.
3746 Also display aliases defined in a global or user modulerc file.
3747 * Exit with error code if error occurred on display or help commands.
3748 * Fix module-info symbols resolution.
3749 * Better handling of .modulerc and .version files when searching for a
3750 modulefile.
3751 * Fix module-info version resolution.
3752 * Fix module-info alias resolution.
3753 * Register alias and version by the short module name and improve their
3754 resolution to avoid loop.
3755 * Source $MODULERCFILE/modulerc when $MODULERCFILE is dir.
3756 * Make it so you can do ``module avail un``, wildcard ``*`` character
3757 implied.
3758
3759
3760 modules-tcl-1.632 (2016-09-06)
3761 ------------------------------
3762
3763 * Raise error if command does not receive the excepted number of arguments.
3764 * Improve column-mode display to get a denser output on ``avail`` command.
3765 * Standardize the output of Warning, Error, InternalBug and ErrorAndExit
3766 messages.
3767 * Add short option -d for --delim on prepend-path.
3768 * Introduce collection target concept to distinguish between machines,
3769 environments or domains that are incompatible with each other.
3770 * Introduce ``saveshow`` command, to display content of saved collections.
3771 * Improve ``save`` and ``restore`` commands to handle collection specified as
3772 absolute or relative file path.
3773 * Introduce ``saverm`` command, to delete saved collections.
3774 * Enable to ``restore`` collection with multiple modulefiles specified on the
3775 same line.
3776 * Fix ``restore`` command when there is no module to load in collection.
3777 * Fix ``restore`` command when collection fully rewind module paths.
3778 * Fix ``restore`` command to preserve module path order set in collection.
3779 * Raise error if try to save an empty environment in a collection.
3780
3781
3782 modules-tcl-1.602 (2016-08-13)
3783 ------------------------------
3784
3785 * Add support for Fish shell.
3786 * Import recent tests added to C-version on 10-use and 50-cmds testsuites.
3787 * Add short option -d for --delim on append-path and remove-path.
3788 * Fix load and implement unload x-resource.
3789 * Fix Python code that was broken or not Python3-compliant. Fixed code is
3790 used to define the module command, to render error and to process
3791 x-resource.
3792 * Always dictionary-sort (also called numerical-sort) list of modulefiles
3793 or list of collections.
3794 * Fix bash completion script to be compliant with bash posix mode.
3795
3796
3797 modules-tcl-1.578 (2014-12-24)
3798 ------------------------------
3799
3800 * First release to be described in this NEWS file but it does not mean this
3801 is the first version of modules-tcl as this Modules flavor is born in
3802 2002.
3803 * At this stage, modules-tcl handles a majority of the module commands and
3804 modulefile Tcl commands available on C version.