[yum-commits] yum/yumRepo.py
zpavlas at osuosl.org
zpavlas at osuosl.org
Mon May 13 06:37:14 UTC 2013
yum/yumRepo.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
New commits:
commit 31a4a3bcb48b67231dc0314d9ed2693eb1e41b6d
Author: Zdenek Pavlas <zpavlas at redhat.com>
Date: Fri May 10 12:23:09 2013 +0200
same-mirror retry also on timeout. BZ 853432
We should be able to retry on timeouts, too.
Works around connection-limited ftpds, that
may block for too long.
diff --git a/yum/yumRepo.py b/yum/yumRepo.py
index 2e4fcd9..41d180e 100644
--- a/yum/yumRepo.py
+++ b/yum/yumRepo.py
@@ -631,8 +631,9 @@ class YumRepository(Repository, config.RepoConf):
def mirror_failure(obj):
action = {}
- # special handling of 503 errors
- if getattr(obj.exception, 'code', 0) == 503:
+ # timeouts and 503 errors may retry
+ e = obj.exception
+ if e.errno == 12 or getattr(e, 'code', 0) == 503:
tries = getattr(obj, 'tries', self.retries)
if tries <= self.retries - len(self.urls):
# don't remove this mirror yet
More information about the Yum-commits
mailing list