Skip to content

Commit 539bb56

Browse files
committed
Merge branch 'export_rpath_wrappers' of github.com:ocaisa/easybuild-framework into export_rpath_wrappers
2 parents dd4d4db + 224e83a commit 539bb56

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+1401
-307
lines changed

.github/workflows/container_tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
ls dist
7575
export PREFIX=/tmp/$USER/$GITHUB_SHA
7676
pip install --prefix $PREFIX dist/easybuild[-_]framework*tar.gz
77-
pip install --prefix $PREFIX https://github.com/easybuilders/easybuild-easyblocks/archive/5.0.x.tar.gz
77+
pip install --prefix $PREFIX https://github.com/easybuilders/easybuild-easyblocks/archive/develop.tar.gz
7878
7979
- name: run test
8080
run: |
@@ -95,7 +95,7 @@ jobs:
9595
echo '%_dbpath %{_var}/lib/rpm' >> $HOME/.rpmmacros
9696
# build CentOS 7 container image for bzip2 1.0.8 using EasyBuild;
9797
# see https://docs.easybuild.io/en/latest/Containers.html
98-
curl -OL https://raw.githubusercontent.com/easybuilders/easybuild-easyconfigs/5.0.x/easybuild/easyconfigs/b/bzip2/bzip2-1.0.8.eb
98+
curl -OL https://raw.githubusercontent.com/easybuilders/easybuild-easyconfigs/develop/easybuild/easyconfigs/b/bzip2/bzip2-1.0.8.eb
9999
export EASYBUILD_CONTAINERPATH=$PWD
100100
export EASYBUILD_CONTAINER_CONFIG='bootstrap=docker,from=ghcr.io/easybuilders/centos-7.9-python3-amd64'
101101
eb bzip2-1.0.8.eb --containerize --experimental --container-build-image

.github/workflows/container_tests_apptainer.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ jobs:
6868
ls dist
6969
export PREFIX=/tmp/$USER/$GITHUB_SHA
7070
pip install --prefix $PREFIX dist/easybuild[-_]framework*tar.gz
71-
pip install --prefix $PREFIX https://github.com/easybuilders/easybuild-easyblocks/archive/5.0.x.tar.gz
71+
pip install --prefix $PREFIX https://github.com/easybuilders/easybuild-easyblocks/archive/develop.tar.gz
7272
7373
- name: run test
7474
run: |
@@ -89,7 +89,7 @@ jobs:
8989
echo '%_dbpath %{_var}/lib/rpm' >> $HOME/.rpmmacros
9090
# build CentOS 7 container image for bzip2 1.0.8 using EasyBuild;
9191
# see https://docs.easybuild.io/en/latest/Containers.html
92-
curl -OL https://raw.githubusercontent.com/easybuilders/easybuild-easyconfigs/5.0.x/easybuild/easyconfigs/b/bzip2/bzip2-1.0.8.eb
92+
curl -OL https://raw.githubusercontent.com/easybuilders/easybuild-easyconfigs/develop/easybuild/easyconfigs/b/bzip2/bzip2-1.0.8.eb
9393
export EASYBUILD_CONTAINERPATH=$PWD
9494
export EASYBUILD_CONTAINER_CONFIG='bootstrap=docker,from=ghcr.io/easybuilders/centos-7.9-python3-amd64'
9595
export EASYBUILD_CONTAINER_TYPE='apptainer'

.github/workflows/end2end.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@ jobs:
2626
run: |
2727
cd $HOME
2828
for pkg in easyblocks easyconfigs; do
29-
curl -OL https://github.com/easybuilders/easybuild-${pkg}/archive/5.0.x.tar.gz
30-
tar xfz 5.0.x.tar.gz
31-
rm -f 5.0.x.tar.gz
29+
curl -OL https://github.com/easybuilders/easybuild-${pkg}/archive/develop.tar.gz
30+
tar xfz develop.tar.gz
31+
rm -f develop.tar.gz
3232
done
3333
3434
- name: Set up environment
3535
shell: bash
3636
run: |
3737
# collect environment variables to be set in subsequent steps in script that can be sourced
3838
echo "export PATH=$PWD:$PATH" > /tmp/eb_env
39-
echo "export PYTHONPATH=$PWD:$HOME/easybuild-easyblocks-5.0.x:$HOME/easybuild-easyconfigs-5.0.x" >> /tmp/eb_env
39+
echo "export PYTHONPATH=$PWD:$HOME/easybuild-easyblocks-develop:$HOME/easybuild-easyconfigs-develop" >> /tmp/eb_env
4040
4141
- name: Run commands to check test environment
4242
shell: bash

RELEASE_NOTES

Lines changed: 141 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,147 @@
11
This file contains a description of the major changes to the easybuild-framework EasyBuild package.
22
For more detailed information, please see the git log.
33

4-
These release notes can also be consulted at https://easybuild.readthedocs.io/en/latest/Release_notes.html.
4+
These release notes can also be consulted at https://docs.easybuild.io/release-notes .
5+
6+
7+
v5.0.0 (18 March 2025)
8+
----------------------
9+
10+
- remove support for Python 2.7 and 3.5 (#4229, #4270, #4306, #4473, #4477, #4476, #4478, #4524, #4607, #4756, #4810, #4811)
11+
- also run unit test suite with Python 3.12 + 3.13 (#4484, #4674)
12+
- changed defaults in EasyBuild configuration:
13+
- enable --trace by default (#4250, #4310, #4311, #4491)
14+
- enable RPATH linking by default (#4448, #4515, #4779)
15+
- disable strict RPATH sanity check by default, allow re-enabling it via `--strict-rpath-sanity-check` configuration option (#4475)
16+
- enable `module-depends-on` by default (#4500)
17+
- enable `module-extensions` by default (#4501)
18+
- set default maximum level of parallellism to `16` via `max-parallel` configuration option (#4606, #4777, #4816)
19+
- use Slurm as the default job backend (#4659)
20+
- enable keeping of symbolic links by default when copying (set `keepsymlinks` easyconfig parameter to `True`) (#4773)
21+
- changed behaviour:
22+
- change default for `change_into_dir` option in `extract_file` function to to `False` (#4246)
23+
- enforce correct `.patch(.*)` extension for patch files (#4247)
24+
- create `lib` -> `lib64` symlink (or vice versa) *before* running `postinstallcmds` (#4435)
25+
- don't allow unresolved templates in easyconfig parameters by default + add support for `--allow-unresolved-templates` configuration option (#4516, #4725, #4726, #4727)
26+
- switch default checksum to `sha256` (#4523)
27+
- only allow use of `rpath` toolchain option when `system` toolchain is used (#4585, #4808)
28+
- use default value `$XDG_CONFIG_DIRS` from XDG basedir spec: `/etc/xdg` (instead of `/etc`) (#4591)
29+
- reverse order for parsing files in `XDG_CONFIG_DIRS` (#4630)
30+
- move verifying of checksums from `source` to `fetch` step, to include it with `--fetch` (#4624, #4729)
31+
- drop support for pep8 package (was used for `--check-contrib` + `--check-style`) (#4634)
32+
- specify changes that should be made by generated module files via `module_load_environment` attribute of `EasyBlock` class (#4653, #4754, #4761, #4774, #4799, #4784, #4801, #4802, #4803, #4809)
33+
- let jobs retweak easyconfigs themselves by passing down `--try-*` options (#4669)
34+
- refactor `make_extension_string` method in `EasyBlock` class (#4690)
35+
- change `Toolchain.get_flag` so it doesn't automatically prepend a dash (`-`) to compiler flags (#4698)
36+
- rename `Compiler.COMPILER*_FLAGS` to `Compiler.COMPILER*_OPTIONS` (#4698)
37+
- change semantics of `--dry-run`, so it doesn't imply `--robot` (#4704)
38+
- run sanity checks commands from an empty temporary directory (rather than the software install directory) (#4723)
39+
- add context manager for allowing unresolved templates and make the state members private (#4735)
40+
- also remove support for directly setting `enable_templating` and `expect_resolved_template_values`
41+
- various enhancements:
42+
- `run_shell_cmd` function to run shell commands which replaces both the (now deprecated) `run_cmd` and `run_cmd_qa` functions (#4284, #4314, #4321, #4322, #4327, #4334, #4335, #4336, #4351, #4356, #4378, #4380, #4383, #4390, #4422, #4423, #4427, #4428, #4430, #4431, #4432, #4441, #4443, #4444, #4453, #4454, #4471, #4504, #4509, #4544, #4612, #4617, #4664, #4721, #4728, #4731, #4755, #4757)
43+
- detect Fortran `.mod` files for installations using `GCCcore` toolchain (#4389)
44+
- create `env.sh` and `cmd.sh` helper scripts in `run_shell_cmd` to allow starting interactive shell to debug failing shell commands (#4486, #4611, #4662, #4666, #4685, #4792)
45+
- add support for alternate easyconfig parameters/templates/constants (#4511, #4514, #4549, #4555)
46+
- create reproducible tarballs for sources created via `git_config` (requires `.tar.xz` + Python 3.9+) (#4248, #4517, #4522, #4660, #4733, #4797, #4798, #4813)
47+
- use more granular exit codes when `EasyBuildError` is raised (#4534)
48+
- prepend to `$PYTHONPATH` or `$EBPYTHONPREFIXES` in generated module files by automatically scanning for Python site package directories (as configured via `prefer-python-search-path`) (#4539, #4686)
49+
- copy build directory and/or log file(s) if installation failed to path specified via `--failed-install-build-dirs-path` or `--failed-install-logs-path` (#4601)
50+
- add `--search-path-cpp-headers` configuration option to control how EasyBuild sets paths to headers at build time (#4645)
51+
- add `module-search-path-headers` configuration option to control how modules set search paths to header files (#4655)
52+
- add `--keep-debug-symbols` configuration option to set default value of '`debug`' toolchain option (#4688, #4764)
53+
- add `--search-path-linker` option to control linker options at build time (#4697)
54+
- don't raise error when required extensions are not found when installing extensions in parallel (#4671)
55+
- mark support for installing extensions in parallel as being mature, since it's no longer experimental (#4672)
56+
- mark easystack support as being mature, since it's no longer experimental (#4673)
57+
- and several additional small enhancements:
58+
- enhance download instructions by mentioning active source path (#4459)
59+
- add CUDA compute capability integer format templates (`cuda_int_*_sep`) (#4463)
60+
- add new `get_cwd` function to `tools.filetools` to retrieve current working directory (#4525)
61+
- use `dict.items()` instead of repeatedly getting the value (#4533)
62+
- set `usedforsecurity` to `False` when calling `hashlib.md5` with Python >= 3.9 (#4550)
63+
- add `GNU_FTP_SOURCE` template constant (#4598)
64+
- allow using `amend/try-amend` multiple times in an easystack file entry (#4667)
65+
- add support for `%(rpath_enabled)s` template value (#4670)
66+
- add `resolve_template` method to `EasyConfig` class (#4677)
67+
- allow templates in `custom_paths` & `custom_commands` sanity-check arguments (#4679)
68+
- updates and fixes for `findPythonDeps` script (#4682, #4740)
69+
- allow use of custom delimiter for paths in module generator (#4687)
70+
- enhance `get_software_libdir` to return full paths if requested (#4699)
71+
- enhance `EasyBlock` class to allow passing in `logfile` (#4707)
72+
- avoid checking loaded module twice in `findUpdatedEcs.sh` script (#4710)
73+
- allow nesting values in checksum dicts (#4711) Flamefire:non-dict MERGED 2024-12-02T12:14:12Z
74+
- use `enumerate` where applicable + fix for `ModuleGenerator._generate_multi_deps_list` (#4720)
75+
- faster `nub` function (#4737)
76+
- enhance `apply_regex_substitutions` to support use of multi-line patterns, requiring matching all patterns in each file, and use pre-compiled regular expressions (#4758)
77+
- ignore other classes if software specific easyblock class was found (#4769)
78+
- also allow trailing whitespaces for `examples` and `citing` easyconfig parameters (#4796)
79+
- enhance `get_gpu_info` to also use `amd-smi` for AMD GPUs if possible (#4805)
80+
- various changes, improvemnents, and fixes for the supported modules tools (Environment Modules + Lmod)
81+
- drop load storm safe guard for Environment Modules v4.2.4+ (#4373)
82+
- run unit tests on an updated versions of Environment Modules: v4.5.3 + v5.3.1 (#4415)
83+
- add `check_group` support for module files in Tcl syntax (#4418)
84+
- bump minimum required Lmod to 8.0.0 (#4424)
85+
- bump minimum required Tmod (4.x) to 4.3.0 (#4425)
86+
- use `getenv` modulefile command with `EnvironmentModules` >= 4.2.0 (#4614)
87+
- add module cache build support in `EnvironmentModules` class (#4615)
88+
- derive `EnvironmentModules` class directly from `ModulesTool` rather than from to be deprecated `EnvironmentModulesTcl` (#4625)
89+
- adapt `module show` command run to cope with non-zero exit code for non-existing module (required for Environment Modules v5.5+ and Lmod 8.7.56+) (#4739)
90+
- various improvements for the framework test suite:
91+
- allow test case filtering by class name (#4788)
92+
- improve test failure output for `assertEqual` (#4807)
93+
- fix `test_modulerc` by taking into account that wrapper module may also be shown as being loaded (#4778)
94+
- (temporarily) use 5.0.x branch for easyblocks + easyconfigs in CI workflows (#4358)
95+
- fix GitHub Actions for CentOS 7.9 container (#4712)
96+
- stop using Ubuntu 20.4 in GitHub Actions workflows, use Ubuntu 22.04 instead (#4783)
97+
- update GitHub actions workflows to use `ubuntu-24.04` where possible (#4795)
98+
- various small bug fixes:
99+
- silence output of included easyblocks for `--terse` (#4765)
100+
- avoid processing the same EasyConfig multiple times (#4767)
101+
- fix easyconfig parameter deprecation (#4479, #4480)
102+
- switch from `ls` to `bash` in tests that are expecting this to be a binary (#4492)
103+
- fix the checksum type check (#4578)
104+
- fix `to_checksums` with `None` values in dicts and recursion (#4579)
105+
- fix `test_toy_lock_cleanup_signals` (#4600)
106+
- resolve symlink when making log dir writable (#4658)
107+
- fix typo in `veryloose` toolchain option for RISC-V (#4668)
108+
- fix dry-run output when using `multi_deps` (#4678)
109+
- make `LooseVersion('1.0') == LooseVersion('1')` (#4691)
110+
- fix FFT entry in `--list-toolchains` output for Cray toolchains (#4719)
111+
- avoid making build directory read-only (#4736)
112+
- deprecated functionality:
113+
- `easybuild.tools.py2vs3` module (#4229)
114+
- rename unclear `*run*` methods to `*install_extension*` + rename `install_extensions` to `install_all_extensions` (#4400)
115+
- deprecate `run_cmd` and `run_cmd_qa` & co, move them to `easybuild._deprecated` module (#4433)
116+
- deprecate support for `EnvironmentModulesC` and `EnvironmentModulesTcl` module tools (#4439)
117+
- deprecate old checksum types (incl. md5) (#4526, #4545)
118+
- deprecate use of `parallel` easyconfig parameter and fix updating the template value (#4580)
119+
- convert template constant lists to dicts and export the constants by name (#4595)
120+
- rename '`source`' step to '`extract`' (affects `skipsteps` easyconfig parameter + `--stop` option) (#4629)
121+
- deprecate `make_module_req_guess` method in `EasyBlock` class (#4653, #4763)
122+
- deprecate support for GC3Pie as job backend (#4659)
123+
- add deprecation warning for `optarch` value without leading dash (#4698)
124+
- deprecate `post_install_step` method in `EasyBlock`, was renamed to `post_processing_step` (#4715)
125+
- remove functionality that was deprecated in EasyBuild v4.x, including:
126+
- EasyBuild bootstrap script (#4233)
127+
- support for YAML-based easyconfig format (.yeb) (#4237)
128+
- `wait-on-lock` configuration setting (#4239)
129+
- `dummy` toolchain (#4240)
130+
- `accept-eula` configuration setting (#4242)
131+
- `is_generic_easyblock` function from `easybuild.framework.easyconfig.easyconfig` (#4243)
132+
- `use_git_am` option for `apply_patch` function (#4244)
133+
- `fetch_extension_sources` method in `EasyBlock` class (#4245)
134+
- support for 32-bit targets (#4272)
135+
- `descr` option for `simple_option` function (#4273)
136+
- `Toolchain.add_dependencies` method (#4274)
137+
- `copytree`, `rmtree2` functions from `easybuild.filetools` (#4275)
138+
- `skip_symlinks` option for `adjust_permissions` function (#4275)
139+
- `log_error` option from `which` function (#4276)
140+
- `skip_lower` option from `template_constant_dict` (#4277)
141+
- `disable_templating` + `default_fallback` options in `get_easyblock_class` (#4278)
142+
- `mod_exists_regex_template` options in `ModulesTool.exist` (#4279)
143+
- other changes
144+
- take into account that `VERBOSE_VERSION` imported from `easybuild.easyblocks` is now a string value (#4357)
5145

6146

7147
v4.9.4 (22 September 2024)

easybuild/base/testing.py

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -55,15 +55,12 @@ def nicediff(txta, txtb, offset=5):
5555
"""
5656
diff = list(difflib.ndiff(txta.splitlines(1), txtb.splitlines(1)))
5757
different_idx = [idx for idx, line in enumerate(diff) if not line.startswith(' ')]
58-
res_idx = []
58+
res_idx = set()
5959
# very bruteforce
6060
for didx in different_idx:
61-
for idx in range(max(didx - offset, 0), min(didx + offset, len(diff) - 1)):
62-
if idx not in res_idx:
63-
res_idx.append(idx)
64-
res_idx.sort()
61+
res_idx.update(range(max(didx - offset, 0), min(didx + offset, len(diff))))
6562
# insert linenumbers too? what are the linenumbers in ndiff?
66-
newdiff = [diff[idx] for idx in res_idx]
63+
newdiff = [diff[idx] for idx in sorted(res_idx)]
6764

6865
return newdiff
6966

@@ -76,17 +73,28 @@ class TestCase(OrigTestCase):
7673
ASSERT_MAX_DIFF = 100
7774
DIFF_OFFSET = 5 # lines of text around changes
7875

79-
# pylint: disable=arguments-differ
76+
def _is_diffable(self, x):
77+
"""Test if it makes sense to show a diff for x"""
78+
if isinstance(x, (int, float, bool, type(None))):
79+
return False
80+
if isinstance(x, str) and '\n' not in x:
81+
return False
82+
return True
83+
84+
# pylint: disable=arguments-differ,arguments-renamed
8085
def assertEqual(self, a, b, msg=None):
8186
"""Make assertEqual always print useful messages"""
8287

8388
try:
84-
super(TestCase, self).assertEqual(a, b)
89+
super(TestCase, self).assertEqual(a, b, msg=msg)
8590
except AssertionError as e:
91+
if not self._is_diffable(a) or not self._is_diffable(b):
92+
raise
93+
8694
if msg is None:
8795
msg = str(e)
8896
else:
89-
msg = "%s: %s" % (msg, e)
97+
msg = "%s: %s" % (msg, str(e))
9098

9199
if isinstance(a, str):
92100
txta = a
@@ -103,7 +111,7 @@ def assertEqual(self, a, b, msg=None):
103111
else:
104112
limit = ''
105113

106-
raise AssertionError("%s:\nDIFF%s:\n%s" % (msg, limit, ''.join(diff[:self.ASSERT_MAX_DIFF])))
114+
raise AssertionError("%s:\nDIFF%s:\n%s" % (msg, limit, ''.join(diff[:self.ASSERT_MAX_DIFF]))) from None
107115

108116
def assertExists(self, path, msg=None):
109117
"""Assert the given path exists"""

0 commit comments

Comments
 (0)