leapp-repository/0068-dnflibs-introduce-DNFError-exception.patch
karolinku dc04575ed7 IPU 9.9 -> 10.3: CTC2 candidate 1
- Requires leapp-framework 6.6+
- Initial implementation of upgrades on systems with configured Software RAID
- Include multipath related configuration in the upgrade environment
- Fix upgrades on systems with multiple LUKS devices
- Fix upgrades for systems with /boot/efi on a Software RAID
- Fix upgrade crashing when dnf repofiles contain URL encoded characters
- Fix mount failures for FSTAB entries with the `nofail` option specified
- Fix upgrade incorrectly resuming during SELinux relabeling
- Fix AVC SELinux warnings
- LiveMode: Fix upgrade getting stuck when the `.leapp_upgrade_failed` file exists
- LiveMode: Fix system version determination in the upgrade environment on CentOS Stream
- Fix target system initramfs containing outdated configuration files in some circumstances
- Inhibit the upgrade when network devices configured with ifcfg files could depend on NM
- Ensure SELinux is set to permissive mode during the upgrade even when enforcing=1 is set on the kernel cmdline
- Fix source and target distribution names in /etc/migration-results
- Fix upgrades with the RealTime kernel on CentOS Stream
- Install the correct kernel for the source system kernel page size on ARM systems
- Introduce rhui.obsolete_gpg_keys configuration option for the removal of obsoleted RPM GPG keys of RHUI Cloud providers
- Detect misconfigured kernel & systemd API mountpoints in FSTAB
- Detect misconfigured /var/run on the source system
- Unify behaviour of upgrades on systems with enabled CRB repositories and explicitly required CRB repositories by user during the upgrade
- Drop the inconsistent report about the use of CRB (unsupported by Red Hat) repositories
- Check and migrate the multipath configuration when possible
- Fix unwanted suspend mode after 15min of inactivity after the upgrade on systems with graphical environment
- Resolves: RHEL-111860, RHEL-115867, RHEL-121205, RHEL-147438, RHEL-148697, RHEL-151509,
 RHEL-154369, RHEL-154370, RHEL-156580, RHEL-161560, RHEL-161684, RHEL-174874
2026-06-25 18:48:05 +02:00

36 lines
1.4 KiB
Diff

From 1b6beff15bf6e5c23feb74ab5bc16ea4c526597b Mon Sep 17 00:00:00 2001
From: Petr Stodulka <pstodulk@redhat.com>
Date: Mon, 4 May 2026 14:46:05 +0200
Subject: [PATCH 068/105] dnflibs: introduce DNFError exception
This is generic exception used for all DNF related errors raised
in dnflibs libraries. IOW, all exceptions introduced in these libraries
are based on DNFError, so if wanted, it's possible to catch a DNFError
exception in calling functions instead of listing each possible DNF
exception separately.
Signed-off-by: Petr Stodulka <pstodulk@redhat.com>
---
repos/system_upgrade/common/libraries/dnflibs/__init__.py | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/repos/system_upgrade/common/libraries/dnflibs/__init__.py b/repos/system_upgrade/common/libraries/dnflibs/__init__.py
index d94e4b4c..1aef3295 100644
--- a/repos/system_upgrade/common/libraries/dnflibs/__init__.py
+++ b/repos/system_upgrade/common/libraries/dnflibs/__init__.py
@@ -6,3 +6,11 @@ This package consolidates DNF functionality previously scattered across:
- leapp.libraries.common.dnfplugin -> dnflibs.dnfplugin
- leapp.libraries.common.module -> dnflibs.dnfmodule
"""
+
+from leapp.exceptions import StopActorExecutionError
+
+
+class DNFError(StopActorExecutionError):
+ """
+ Generic exception inherited by all DNF errors raised in dnflibs libraries.
+ """
--
2.54.0