From 53227e0f8e760bbc4c3b071d81ea23c269ced59b Mon Sep 17 00:00:00 2001 From: N0VA Date: Mon, 9 Feb 2026 19:05:27 +0100 Subject: [PATCH] Fix UEFI grub2-install: add missing modules package and fix DNF stderr logging --- iridium_installer/backend/os_install.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/iridium_installer/backend/os_install.py b/iridium_installer/backend/os_install.py index b0aefc7..06756b3 100644 --- a/iridium_installer/backend/os_install.py +++ b/iridium_installer/backend/os_install.py @@ -50,8 +50,9 @@ def run_command(cmd, check=True): t1 = threading.Thread( target=read_stream, args=(process.stdout, stdout_lines, logger.info) ) + # Log stderr as INFO to avoid Discord notification spam, but still capture it t2 = threading.Thread( - target=read_stream, args=(process.stderr, stderr_lines, logger.error) + target=read_stream, args=(process.stderr, stderr_lines, logger.info) ) t1.start() @@ -66,8 +67,9 @@ def run_command(cmd, check=True): stderr_str = "".join(stderr_lines) if check and returncode != 0: - error_msg = f"Command '{' '.join(cmd)}' failed with exit code {returncode}\nStderr: {stderr_str}" - log_to_discord("ERROR", error_msg, module="os_install") + error_msg = f"Command failed: {' '.join(cmd)}\nExit Code: {returncode}\nStderr: {stderr_str}" + # Log this specific failure as ERROR so it DOES go to Discord + logger.error(error_msg) raise subprocess.CalledProcessError( returncode, cmd, output=stdout_str, stderr=stderr_str ) @@ -148,7 +150,7 @@ def install_minimal_os(mount_root, releasever="43"): ] if uefi: - packages += ["grub2-efi-x64", "shim-x64", "efibootmgr"] + packages += ["grub2-efi-x64", "grub2-efi-x64-modules", "shim-x64", "efibootmgr"] else: packages += ["grub2-pc"]