-
Notifications
You must be signed in to change notification settings - Fork 218
adds support for including 'extensions' statement in Lua modules with Lmod 8.2+ #3085
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
* develop: (413 commits) bump version to 4.0.2dev tweak release notes and bump version for v4.0.1 release prepare release notes for eb401 extend test_build_easyconfigs_in_parallel_gc3pie to also check for raised error when a job failed improve error message for jobs that failed when using GC3Pie job backend appease the Hound fix join for Tcl module syntax in test_toy_ghost_installdir make removal of ghost installation directories opt-in remove installation directory used by module file that is replaced under --force, to avoid leaving behind a 'ghost' installation add ModuleGenerator.det_installdir method to determine installation directory used by a given module file use remove_dir + move_file functions in EasyBlock.make_dir Fix wrong function invocation in last commit. Report what build jobs actually failed. fix broken test for get_paths_for appease the Hound only consider resolved path to 'eb' script if desired subdir is not found relative to 'eb' script location in get_paths_for enhance test for get_paths_for define $EB_SCRIPT_PATH in 'eb' wrapper script, and consider it before location of 'eb' determined via $PATH in get_paths_for function Error out if some GC3Pie job failed. better filtering + logging in test for move_logs ...
* origin/develop: (74 commits) always include mandatory easyconfig parameters in dumped easyconfig file, regardless of whether default value is used or not add support for is_mandatory_key method in EasyConfig class silence deprecation warning for Python 2.6 when testing with Python 2.6 also test with Lmod 8.2.3 in GitHub CI ensure 'silence_deprecation_warnings' build option is correctly set in tests correctly silence deprecation warning for Lmod 6.x in Travis CI config add support for --silence-deprecation-warnings, and use it to avoid deprecation warnings breaking tests when testing with Lmod 6.x update help message for --external-modules-metadata fix trivial code style issue fix module version cache check keep testing single configuration in Travis CI with Lmod 6.5.1 don't test non-Lmod module tools with Python 3.8 also test with Python 3.8 in Travis CI take into account that platform.dist was removed in Python 3.8 in get_os_version, leverage distro package if available deprecate running EasyBuild with Python 2.6 via new check_python_version() function stop testing with Lmod 6.x in GitHub Actions stop testing with Lmod 6.x in Travis CI, update to Lmod 8.2.3, favor testing with Python 2.7 over 2.6 (+ cleanup) fix broken test_lmod_specific, use DEPR_VERSION rather than REQ_VERSION take into account that platform.linux_distribution was removed in Python 3.8 in get_os_name, leverage distro package if available deprecate support for using Lmod 6.x ...
easybuild/tools/module_generator.py
Outdated
| provide_list = self._generate_provides_list() | ||
| if self.modules_tool.supports_extensions and provide_list: | ||
| provide_list_str = ', '.join(['"%s"' % x for x in provide_list]) | ||
| lines.extend(['', 'extensions(%s)' % provide_list_str]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have two options here:
- either we include this if the Lmod version used at installation time is recent enough (which is what you're doing here)
- or we add a conditional in the module file itself, using
LmodVersion()(that's what @rtmclay recommended)
The benefit of the latter approach is that the module files will still work when loaded with an older Lmod version, and there's basically no overhead in using the conditional.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a design choice, I don't have a strong preference for either.
But adding support in a module file for something that doesn't work with the current Lmod seems a bit weird to me? Especially as it's pretty easy to regenerate a module.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, it might surprise people. You update Lmod and suddenly the output of av etc changes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a protection mechanism too though. You may be installing software on a system with a slightly more recent version of Lmod (8.2+), and then consume the modules elsewhere with a slightly older Lmod (<8.2).
That wouldn't be very nice either... It's certainly less serious than being a bit careful and only using extensions conditionally.
Output of ml av will change anyway as soon as you install something with extensions after updating to Lmod 8.2, and you're probably not going to notice straight away (I certainly rarely check the generated module files mannually ;) ).
|
@wpoely86 Tests are still broken when using Lmod 8.2+ (@boegelbot only reports broken tests from Travis CI). |
We need a Lmod version check and it's simple a complete pain in Tcl.
boegel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wpoely86 Some minor suggestions, it's pretty much good to go imho...
…o modprovides * 'modprovides' of github:wpoely86/easybuild-framework: drop forgotten print statement
minor style fixes in module_generator.py w.r.t. extensions support
Lmod 8.2 supports now extensions, this PR makes EB generate the needed lines in the module files for it.