Blame SOURCES/0018-Fix-processing-of-download-errors-RhBug-2024527.patch

bc72d2
From 9bd0423e1e543ed5f83924ec61aa253eced24cf8 Mon Sep 17 00:00:00 2001
bc72d2
From: Marek Blaha <mblaha@redhat.com>
bc72d2
Date: Mon, 14 Mar 2022 09:49:52 +0100
bc72d2
Subject: [PATCH] Fix processing of download errors (RhBug: 2024527)
bc72d2
bc72d2
Users with different than english locale are not able to update their
bc72d2
systems in case that some of updates are already downloaded in the dnf
bc72d2
cache (e.g. using dnf-automatic).
bc72d2
bc72d2
The error string is taken from librepo target where it is stored
bc72d2
untranslated. Therefore we need to compare untranslated versions of the
bc72d2
string.
bc72d2
bc72d2
= changelog =
bc72d2
msg:           Fix download errors handling in non-english locales
bc72d2
type:          bugfix
bc72d2
resolves:      https://bugzilla.redhat.com/show_bug.cgi?id=2024527
bc72d2
---
bc72d2
 dnf/repo.py | 2 +-
bc72d2
 1 file changed, 1 insertion(+), 1 deletion(-)
bc72d2
bc72d2
diff --git a/dnf/repo.py b/dnf/repo.py
bc72d2
index 1822cf01..ec1a2537 100644
bc72d2
--- a/dnf/repo.py
bc72d2
+++ b/dnf/repo.py
bc72d2
@@ -108,7 +108,7 @@ def _download_payloads(payloads, drpm, fail_fast=True):
bc72d2
         callbacks = tgt.getCallbacks()
bc72d2
         payload = callbacks.package_pload
bc72d2
         pkg = payload.pkg
bc72d2
-        if err == _('Already downloaded'):
bc72d2
+        if err == 'Already downloaded':
bc72d2
             errs._skipped.add(pkg)
bc72d2
             continue
bc72d2
         pkg.repo._repo.expire()
bc72d2
-- 
bc72d2
2.35.1
bc72d2