Skip to content

Conversation

Flamefire
Copy link
Contributor

This is a similar fix as easybuilders/easybuild-easyconfigs#15973

check_checksums had various shortcomings, some touched by 7112e40 (from @boegel ) which disabled templating entirely when getting the exts_list list.

This breaks when checksums.json is used: It will report missing checksums even when they are available in the checksums.json
Additionally templates in the name/version of extension won't be resolved causing the error message harder to understand

A quick fix was to replace the above commit by allow_unresolved_templates-decorator to allow partially resolved extensions but don't fail as before when templates are used e.g. in install_cmd which fixes the issues with the name/version of the extension

However that resolves too deep as inside the extension options different template values must be used.

We have collect_exts_file_info which does handle all those peculiarities of the extension specs already so just use that.

This also handles the default file name of extension sources and nosource which we can rely on here if it fills sources correctly. This requires #4054 (merged here so that tests pass)

It also fixes a failure when patches were specified as dicts as In sources the keyname is "filename" while in patches it is "name" which causes a KeyError in check_checksums_for

…le_info`

The returned dict per extension has a 'patches' key but no 'sources'.
Add this incoorporating `source_tmpl` or the default value.
Add test for that and also for `nosource: True` and `sources` being a list.
In `sources` the keyname is "filename" while in `patches` it is "name".
…st' easyconfig parameter value in EasyBlock.check_checksums"

This reverts commit 7112e40.
This requires correctly resolving the templates in `exts_list`
sources/patches to be able to fetch them from the JSON file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant