Skip to content

Conversation

@Thyre
Copy link
Collaborator

@Thyre Thyre commented Oct 26, 2025

(created using eb --new-pr)

Fixes the following build failure when e.g. only building the sanity check of LLVM 20.1.7:

== Summary:
   * [FAILED]  Compiler/GCCcore/14.2.0/LLVM/20.1.7

EasyBuild crashed! Please consider reporting a bug, this should not happen...

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 833, in <module>
    main_with_hooks()
    ~~~~~~~~~~~~~~~^^
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 819, in main_with_hooks
    main(args=args, prepared_cfg_data=(init_session_state, eb_go, cfg_settings))
    ~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 774, in main
    do_cleanup = process_eb_args(orig_paths, eb_go, cfg_settings, modtool, testing, init_session_state,
                                 hooks, do_build)
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 593, in process_eb_args
    ecs_with_res = build_and_install_software(
        ordered_ecs, init_session_state, exit_on_failure=exit_on_failure, testing=testing)
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 207, in build_and_install_software
    raise error
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/main.py", line 161, in build_and_install_software
    (ec_res['success'], app_log, err_msg, err_code) = build_and_install_one(ec, init_env)
                                                      ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/framework/easyblock.py", line 5081, in build_and_install_one
    result = app.run_all_steps(run_test_cases=run_test_cases)
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/framework/easyblock.py", line 4894, in run_all_steps
    self.run_step(step_name, step_methods)
    ~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/framework/easyblock.py", line 4735, in run_step
    current_method()
    ~~~~~~~~~~~~~~^^
  File "/data/EasyBuild/lib/python3.13/site-packages/easybuild/easyblocks/l/llvm.py", line 1669, in sanity_check_step
    if self.nvptx_target_cond:
       ^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'EB_LLVM' object has no attribute 'nvptx_target_cond'

@Thyre Thyre added this to the next release (5.2.0?) milestone Oct 26, 2025
@Thyre
Copy link
Collaborator Author

Thyre commented Oct 26, 2025

Test report by @Thyre

Overview of tested easyconfigs (in order)

  • SUCCESS LLVM-20.1.7-GCCcore-14.2.0.eb

Build succeeded for 1 out of 1 (1 easyconfigs in total)
Linux - Linux Arch Linux UNKNOWN, x86_64, AMD Ryzen 7 7800X3D 8-Core Processor (zen4), 1 x AMD Navi 48 [Radeon RX 9070/9070 XT/9070 GRE] (device id: 0x7550, gfx: gfx1201, driver: Linuxversion6.17.4-arch2-1(linux@archlinux)(gcc(GCC)15.2.120250813,GNUld(GNUBinutils)2.45.0)#1SMPPREEMPT_DYNAMICSun,19Oct202519:21:18+0000), 1 x AMD Raphael (device id: 0x164e, gfx: gfx1036, driver: Linuxversion6.17.4-arch2-1(linux@archlinux)(gcc(GCC)15.2.120250813,GNUld(GNUBinutils)2.45.0)#1SMPPREEMPT_DYNAMICSun,19Oct202519:21:18+0000), Python 3.13.7
See https://gist.github.com/Thyre/de71e3dd574fc4b45c18873a5722068f for a full test report.

@Thyre Thyre added the bug fix label Oct 26, 2025
@Thyre
Copy link
Collaborator Author

Thyre commented Oct 26, 2025

@boegelbot please test @ jsc-zen3
EB_ARGS="--sanity-check-only LLVM-20.1.7-GCCcore-14.2.0.eb"

@Thyre
Copy link
Collaborator Author

Thyre commented Oct 26, 2025

Alternatively, one could move the entire _configure_build_targets call to __init__. I don't see anything that requires further setup, but maybe I'm missing something @Crivella ?

@boegelbot
Copy link

@Thyre: Request for testing this PR well received on jsczen3l1.int.jsc-zen3.fz-juelich.de

PR test command 'if [[ develop != 'develop' ]]; then EB_BRANCH=develop ./easybuild_develop.sh 2> /dev/null 1>&2; EB_PREFIX=/home/boegelbot/easybuild/develop source init_env_easybuild_develop.sh; fi; EB_PR=3977 EB_ARGS="--sanity-check-only LLVM-20.1.7-GCCcore-14.2.0.eb" EB_CONTAINER= EB_REPO=easybuild-easyblocks EB_BRANCH=develop /opt/software/slurm/bin/sbatch --job-name test_PR_3977 --ntasks=8 ~/boegelbot/eb_from_pr_upload_jsc-zen3.sh' executed!

  • exit code: 0
  • output:
Submitted batch job 8557

Test results coming soon (I hope)...

- notification for comment with ID 3448886233 processed

Message to humans: this is just bookkeeping information for me,
it is of no use to you (unless you think I have a bug, which I don't).

@boegelbot
Copy link

Test report by @boegelbot

Overview of tested easyconfigs (in order)

  • SUCCESS LLVM-20.1.7-GCCcore-14.2.0.eb

Build succeeded for 1 out of 1 (1 easyconfigs in total)
jsczen3c2.int.jsc-zen3.fz-juelich.de - Linux Rocky Linux 9.6, x86_64, AMD EPYC-Milan Processor (zen3), Python 3.9.21
See https://gist.github.com/boegelbot/022b6fc91e4994da6ea82a183c7aad82 for a full test report.

@Crivella
Copy link
Contributor

Alternatively, one could move the entire _configure_build_targets call to init. I don't see anything that requires further setup, but maybe I'm missing something @Crivella ?

I am not sure that will be possible.
The reason we moved as much stuff as possible out of the init is to not break things with Bundles if i recall correctly

@Crivella
Copy link
Contributor

One thing we might be able to do is similarly to gcc_prefix we could make the flags set by this function a property, but we would need to make sure it is reset across steps in bundles

@Thyre
Copy link
Collaborator Author

Thyre commented Oct 27, 2025

In that case, I would keep the currently proposed approach in this PR. The sanity check may check less files than it should check, but it doesn't crash anymore at least...

@Crivella
Copy link
Contributor

Yeah agree the enhancement should be for another PR

Copy link
Contributor

@Crivella Crivella left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Crivella
Copy link
Contributor

Going in, thanks @Thyre!

@Crivella Crivella merged commit e88a534 into easybuilders:develop Oct 27, 2025
22 checks passed
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