From ab03e42d360615591cbe313ed7df4e5b7371a720 Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 14:24:48 +0200 Subject: [PATCH 1/8] Fix copying of the buildlogs broken by the introduction of pre-run-shell-cmd --- EESSI-install-software.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index e4834545..671f6532 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -412,12 +412,14 @@ else # copy EasyBuild log file if EasyBuild exited with an error if [ ${ec} -ne 0 ]; then - eb_last_log=$(unset EB_VERBOSE; eb --last-log) + eb_hooks=$EASYBUILD_HOOKS + eb_last_log=$(unset EB_VERBOSE; unset EASYBUILD_HOOKS; eb --last-log) # copy to current working directory cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" # copy to build logs dir (with context added) copy_build_log "${eb_last_log}" "${build_logs_dir}" + export EASYBUILD_HOOKS=$eb_hooks fi $TOPDIR/check_missing_installations.sh ${easystack_file} ${pr_diff} From 8fb1f952a66cd2f35fe6f7b9eb693deeac8bd81c Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 14:34:38 +0200 Subject: [PATCH 2/8] Fix copying of the buildlogs broken by the introduction of pre-run-shell-cmd --- EESSI-install-software.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index 671f6532..56030bf7 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -412,14 +412,12 @@ else # copy EasyBuild log file if EasyBuild exited with an error if [ ${ec} -ne 0 ]; then - eb_hooks=$EASYBUILD_HOOKS - eb_last_log=$(unset EB_VERBOSE; unset EASYBUILD_HOOKS; eb --last-log) + eb_last_log=$(eb --last-log | grep | grep -vE "==|>>") # copy to current working directory cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" # copy to build logs dir (with context added) copy_build_log "${eb_last_log}" "${build_logs_dir}" - export EASYBUILD_HOOKS=$eb_hooks fi $TOPDIR/check_missing_installations.sh ${easystack_file} ${pr_diff} From fc112077bda1a76441932138bf6268831c45572b Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 14:36:01 +0200 Subject: [PATCH 3/8] fix typo --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index 56030bf7..e8cee893 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -412,7 +412,7 @@ else # copy EasyBuild log file if EasyBuild exited with an error if [ ${ec} -ne 0 ]; then - eb_last_log=$(eb --last-log | grep | grep -vE "==|>>") + eb_last_log=$(eb --last-log | grep -vE "==|>>") # copy to current working directory cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" From b12aefcda79963fc8683a22f453a3eade23e0e06 Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 14:54:46 +0200 Subject: [PATCH 4/8] use match instead of reverse match --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index e8cee893..c1ce4a79 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -412,7 +412,7 @@ else # copy EasyBuild log file if EasyBuild exited with an error if [ ${ec} -ne 0 ]; then - eb_last_log=$(eb --last-log | grep -vE "==|>>") + eb_last_log=$(eb --last-log | grep ^/.*\.log) # copy to current working directory cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" From 01079f167e33095e0347faae2f61b421a1eee352 Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 15:02:13 +0200 Subject: [PATCH 5/8] add check if file exhists --- EESSI-install-software.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index c1ce4a79..46865a2e 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -413,11 +413,15 @@ else # copy EasyBuild log file if EasyBuild exited with an error if [ ${ec} -ne 0 ]; then eb_last_log=$(eb --last-log | grep ^/.*\.log) - # copy to current working directory - cp -a ${eb_last_log} . - echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" - # copy to build logs dir (with context added) - copy_build_log "${eb_last_log}" "${build_logs_dir}" + # copy to current working directory if file exhists + if [ -e ${eb_last_log} ]; then + cp -a ${eb_last_log} . + echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" + # copy to build logs dir (with context added) + copy_build_log "${eb_last_log}" "${build_logs_dir}" + else + fatal_error "Could not copy EasyBuild log file because ${eb_last_log} does not exhist" + fi fi $TOPDIR/check_missing_installations.sh ${easystack_file} ${pr_diff} From 10155c10a44c86c02e5237e1969fd8a8b1635d65 Mon Sep 17 00:00:00 2001 From: laraPPr Date: Wed, 8 Apr 2026 15:03:13 +0200 Subject: [PATCH 6/8] fix identation --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index 46865a2e..ceac23d2 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -414,7 +414,7 @@ else if [ ${ec} -ne 0 ]; then eb_last_log=$(eb --last-log | grep ^/.*\.log) # copy to current working directory if file exhists - if [ -e ${eb_last_log} ]; then + if [ -e ${eb_last_log} ]; then cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" # copy to build logs dir (with context added) From b9f9a4d5421728b885890e02c4e90d2b17ab8089 Mon Sep 17 00:00:00 2001 From: Lara Ramona Peeters <49882639+laraPPr@users.noreply.github.com> Date: Wed, 8 Apr 2026 15:07:49 +0200 Subject: [PATCH 7/8] Update EESSI-install-software.sh Co-authored-by: Caspar van Leeuwen <33718780+casparvl@users.noreply.github.com> --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index ceac23d2..3b310728 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -414,7 +414,7 @@ else if [ ${ec} -ne 0 ]; then eb_last_log=$(eb --last-log | grep ^/.*\.log) # copy to current working directory if file exhists - if [ -e ${eb_last_log} ]; then + if [ -f ${eb_last_log} ]; then cp -a ${eb_last_log} . echo "Last EasyBuild log file copied from ${eb_last_log} to ${PWD}" # copy to build logs dir (with context added) From 27b6bd64d80d9306caf1a87e5d92b8ed73b79f57 Mon Sep 17 00:00:00 2001 From: ocaisa Date: Wed, 8 Apr 2026 15:08:17 +0200 Subject: [PATCH 8/8] Apply suggestion from @ocaisa --- EESSI-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-install-software.sh b/EESSI-install-software.sh index 3b310728..2c674ae8 100755 --- a/EESSI-install-software.sh +++ b/EESSI-install-software.sh @@ -420,7 +420,7 @@ else # copy to build logs dir (with context added) copy_build_log "${eb_last_log}" "${build_logs_dir}" else - fatal_error "Could not copy EasyBuild log file because ${eb_last_log} does not exhist" + fatal_error "Could not copy EasyBuild log file because ${eb_last_log} does not exist" fi fi