Update ELevate patch: rabase to upstream 0.21.0-5

Bump version to 0.21.0-5.elevate.1
This commit is contained in:
Yuriy Kohut 2025-01-23 12:29:58 +02:00
parent 1377bbc817
commit ad6242eca3
2 changed files with 32 additions and 28 deletions

View File

@ -3874,7 +3874,7 @@ index f24dda68..7ee5d016 100644
all_events = list(chain(*[parse_entry(entry) for entry in events_data['packageinfo']])) all_events = list(chain(*[parse_entry(entry) for entry in events_data['packageinfo']]))
diff --git a/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py b/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py diff --git a/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py b/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py
index f5cb2613..10e27220 100644 index 50336150..540182a5 100644
--- a/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py --- a/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py
+++ b/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py +++ b/repos/system_upgrade/common/actors/peseventsscanner/libraries/pes_events_scanner.py
@@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
@ -3913,24 +3913,24 @@ index f5cb2613..10e27220 100644
def get_cloud_provider_name(cloud_provider_variant): def get_cloud_provider_name(cloud_provider_variant):
@@ -83,7 +87,7 @@ def get_transaction_configuration(): @@ -86,7 +90,7 @@ def get_transaction_configuration():
These configuration files have higher priority than PES data.
:return: RpmTransactionTasks model instance :return: TransactionConfiguration
""" """
- transaction_configuration = TransactionConfiguration(to_install=[], to_remove=[], to_keep=[]) - transaction_configuration = TransactionConfiguration(to_install=set(), to_remove=set(), to_keep=set())
+ transaction_configuration = TransactionConfiguration(to_install=[], to_remove=[], to_keep=[], to_reinstall=[]) + transaction_configuration = TransactionConfiguration(to_install=set(), to_remove=set(), to_keep=set(), to_reinstall=set())
_Pkg = partial(Package, repository=None, modulestream=None) _Pkg = partial(Package, repository=None, modulestream=None)
@@ -91,6 +95,7 @@ def get_transaction_configuration(): @@ -94,6 +98,7 @@ def get_transaction_configuration():
transaction_configuration.to_install.extend(_Pkg(name=pkg_name) for pkg_name in tasks.to_install) transaction_configuration.to_install.update(_Pkg(name=pkg_name) for pkg_name in tasks.to_install)
transaction_configuration.to_remove.extend(_Pkg(name=pkg_name) for pkg_name in tasks.to_remove) transaction_configuration.to_remove.update(_Pkg(name=pkg_name) for pkg_name in tasks.to_remove)
transaction_configuration.to_keep.extend(_Pkg(name=pkg_name) for pkg_name in tasks.to_keep) transaction_configuration.to_keep.update(_Pkg(name=pkg_name) for pkg_name in tasks.to_keep)
+ transaction_configuration.to_reinstall.extend(_Pkg(name=pkg_name) for pkg_name in tasks.to_reinstall) + transaction_configuration.to_reinstall.update(_Pkg(name=pkg_name) for pkg_name in tasks.to_reinstall)
return transaction_configuration return transaction_configuration
@@ -130,6 +135,7 @@ def compute_pkg_changes_between_consequent_releases(source_installed_pkgs, @@ -133,6 +138,7 @@ def compute_pkg_changes_between_consequent_releases(source_installed_pkgs,
logger = api.current_logger() logger = api.current_logger()
# Start with the installed packages and modify the set according to release events # Start with the installed packages and modify the set according to release events
target_pkgs = set(source_installed_pkgs) target_pkgs = set(source_installed_pkgs)
@ -3938,7 +3938,7 @@ index f5cb2613..10e27220 100644
release_events = [e for e in events if e.to_release == release] release_events = [e for e in events if e.to_release == release]
@@ -173,9 +179,12 @@ def compute_pkg_changes_between_consequent_releases(source_installed_pkgs, @@ -176,9 +182,12 @@ def compute_pkg_changes_between_consequent_releases(source_installed_pkgs,
target_pkgs = target_pkgs.difference(event.out_pkgs) target_pkgs = target_pkgs.difference(event.out_pkgs)
target_pkgs = target_pkgs.union(event.out_pkgs) target_pkgs = target_pkgs.union(event.out_pkgs)
@ -3952,7 +3952,7 @@ index f5cb2613..10e27220 100644
def remove_undesired_events(events, relevant_to_releases): def remove_undesired_events(events, relevant_to_releases):
@@ -241,15 +250,17 @@ def compute_packages_on_target_system(source_pkgs, events, releases): @@ -244,15 +253,17 @@ def compute_packages_on_target_system(source_pkgs, events, releases):
did_processing_cross_major_version = True did_processing_cross_major_version = True
pkgs_to_demodularize = {pkg for pkg in target_pkgs if pkg.modulestream} pkgs_to_demodularize = {pkg for pkg in target_pkgs if pkg.modulestream}
@ -3974,7 +3974,7 @@ index f5cb2613..10e27220 100644
def compute_rpm_tasks_from_pkg_set_diff(source_pkgs, target_pkgs, pkgs_to_demodularize): def compute_rpm_tasks_from_pkg_set_diff(source_pkgs, target_pkgs, pkgs_to_demodularize):
@@ -353,15 +364,13 @@ def get_pesid_to_repoid_map(target_pesids): @@ -356,15 +367,13 @@ def get_pesid_to_repoid_map(target_pesids):
:return: Dictionary mapping the target_pesids to their corresponding repoid :return: Dictionary mapping the target_pesids to their corresponding repoid
""" """
@ -3993,7 +3993,7 @@ index f5cb2613..10e27220 100644
rhui_info = next(api.consume(RHUIInfo), None) rhui_info = next(api.consume(RHUIInfo), None)
cloud_provider = rhui_info.provider if rhui_info else '' cloud_provider = rhui_info.provider if rhui_info else ''
@@ -507,6 +516,19 @@ def process(): @@ -553,6 +562,19 @@ def process():
if not events: if not events:
return return
@ -4011,20 +4011,20 @@ index f5cb2613..10e27220 100644
+ events.extend(vendor_events) + events.extend(vendor_events)
+ +
releases = get_relevant_releases(events) releases = get_relevant_releases(events)
source_pkgs = get_installed_pkgs() installed_pkgs = get_installed_pkgs()
source_pkgs = apply_transaction_configuration(source_pkgs) transaction_configuration = get_transaction_configuration()
@@ -519,7 +541,7 @@ def process(): @@ -566,7 +588,7 @@ def process():
events = remove_undesired_events(events, releases) events = remove_undesired_events(events, releases)
# Apply events - compute what packages should the target system have # Apply events - compute what packages should the target system have
- target_pkgs, pkgs_to_demodularize = compute_packages_on_target_system(source_pkgs, events, releases) - target_pkgs, pkgs_to_demodularize = compute_packages_on_target_system(pkgs_to_begin_computation_with,
+ target_pkgs, pkgs_to_demodularize, pkgs_to_reinstall = compute_packages_on_target_system(source_pkgs, events, releases) + target_pkgs, pkgs_to_demodularize, pkgs_to_reinstall = compute_packages_on_target_system(pkgs_to_begin_computation_with,
events, releases)
# Packages coming out of the events have PESID as their repository, however, we need real repoid # Packages coming out of the events have PESID as their repository, however, we need real repoid
target_pkgs = replace_pesids_with_repoids_in_packages(target_pkgs, repoids_of_source_pkgs) @@ -586,4 +608,5 @@ def process():
@@ -535,4 +557,5 @@ def process(): rpm_tasks = include_instructions_from_transaction_configuration(rpm_tasks, transaction_configuration,
# Compare the packages on source system and the computed packages on target system and determine what to install installed_pkgs)
rpm_tasks = compute_rpm_tasks_from_pkg_set_diff(source_pkgs, target_pkgs, pkgs_to_demodularize)
if rpm_tasks: if rpm_tasks:
+ rpm_tasks.to_reinstall = sorted(pkgs_to_reinstall) + rpm_tasks.to_reinstall = sorted(pkgs_to_reinstall)
api.produce(rpm_tasks) api.produce(rpm_tasks)
@ -4963,7 +4963,7 @@ index 00000000..a53775cf
+ } + }
+} +}
diff --git a/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json b/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json diff --git a/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json b/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json
index 8a5471a8..dde34c9d 100644 index 3cc67f82..c1f4acf4 100644
--- a/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json --- a/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json
+++ b/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json +++ b/repos/system_upgrade/common/files/distro/rhel/gpg-signatures.json
@@ -4,7 +4,9 @@ @@ -4,7 +4,9 @@
@ -4988,7 +4988,7 @@ index 8a5471a8..dde34c9d 100644
+ "gpg-pubkey-6275f250-5e26cb2e", + "gpg-pubkey-6275f250-5e26cb2e",
+ "gpg-pubkey-73e3b907-6581b071" + "gpg-pubkey-73e3b907-6581b071"
+ ], + ],
"10": [] "10": ["gpg-pubkey-fd431d51-4ae0493b"]
} }
} }
diff --git a/repos/system_upgrade/common/files/distro/rocky/gpg-signatures.json b/repos/system_upgrade/common/files/distro/rocky/gpg-signatures.json diff --git a/repos/system_upgrade/common/files/distro/rocky/gpg-signatures.json b/repos/system_upgrade/common/files/distro/rocky/gpg-signatures.json

View File

@ -53,7 +53,7 @@ py2_byte_compile "%1" "%2"}
Epoch: 1 Epoch: 1
Name: leapp-repository Name: leapp-repository
Version: 0.21.0 Version: 0.21.0
Release: 5%{?dist} Release: 5%{?dist}.elevate.1
Summary: Repositories for leapp Summary: Repositories for leapp
License: ASL 2.0 License: ASL 2.0
@ -427,6 +427,10 @@ done;
# no files here # no files here
%changelog %changelog
* Thu Jan 23 2025 Yuriy Kohut <ykohut@almalinux.org> - 0.21.0-5.elevate.1
- Update ELevate patch:
- rabase to upstream 0.21.0-5
* Fri Jan 17 2025 Petr Stodulka <pstodulk@redhat.com> - 0.21.0-5 * Fri Jan 17 2025 Petr Stodulka <pstodulk@redhat.com> - 0.21.0-5
- Fix pes events scanner crashing when there are duplicate packages in the received instructions - Fix pes events scanner crashing when there are duplicate packages in the received instructions
- Fix pes events scanner not respecting users transaction configuration - Fix pes events scanner not respecting users transaction configuration