Skip to content

Conversation

@mboisson
Copy link
Contributor

@mboisson mboisson commented May 5, 2020

For whatever reason, one of our dependencies has the following form (once converted to string) :

{'full_mod_name': 'Core/scipy-stack/2019a', 'short_mod_name': 'scipy-stack/2019a', 'name': 'SciPy-Stack', 'version': '2019a', 'versionsuffix': None, 'toolchain': {'name': 'system', 'version': ''}, 'toolchain_inherited': False, 'system': True, 'hidden': False, 'build_only': True, 'external_module': False, 'external_module_metadata': {}}

i.e. versionsuffix is explicitly set to None.

This causes an error when concatenating to get full_versionsuffix :

{'full_mod_name': 'Core/scipy-stack/2019a', 'short_mod_name': 'scipy-stack/2019a', 'name': 'SciPy-Stack', 'version': '2019a', 'versionsuffix': None, 'toolchain': {'name': 'system', 'version': ''}, 'toolchain_inherited': False, 'system': True, 'hidden': False, 'build_only': True, 'external_module': False, 'external_module_metadata': {}}  None .eb
Traceback (most recent call last):
  File "/cvmfs/soft.computecanada.ca/gentoo/2019/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/cvmfs/soft.computecanada.ca/gentoo/2019/usr/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/mboisson/git/easybuild-framework/easybuild/main.py", line 518, in <module>
    main()
  File "/home/mboisson/git/easybuild-framework/easybuild/main.py", line 382, in main
    easyconfigs = tweak(easyconfigs, build_specs, modtool, targetdirs=tweaked_ecs_paths)
  File "/home/mboisson/git/easybuild-framework/easybuild/framework/easyconfig/tweak.py", line 220, in tweak
    update_dep_versions=update_dependencies)
  File "/home/mboisson/git/easybuild-framework/easybuild/framework/easyconfig/tweak.py", line 1031, in map_easyconfig_to_target_tc_hierarchy
    versionsuffix_mapping=versonsuffix_mapping)
  File "/home/mboisson/git/easybuild-framework/easybuild/framework/easyconfig/tweak.py", line 1124, in find_potential_version_mappings
    full_versionsuffix = toolchain_suffix + versionsuffix + EB_FORMAT_EXTENSION
TypeError: can only concatenate str (not "NoneType") to str

@boegel boegel added the bug fix label May 5, 2020
@boegel boegel added this to the next release (4.2.1?) milestone May 5, 2020
@mboisson mboisson changed the title if versionsuffix is explicitly set to None, it crashes below A couple of bug fixes with tweak.py for --try-update-deps May 5, 2020
@mboisson
Copy link
Contributor Author

mboisson commented May 5, 2020

Requesting comment from @ocaisa

@mboisson
Copy link
Contributor Author

mboisson commented May 6, 2020 via email

@ocaisa ocaisa merged commit 7027f32 into easybuilders:develop May 6, 2020
@mboisson mboisson deleted the fix_tweak branch May 6, 2020 19:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants