From 59c3843f3a37eda3709cce2a1208385a6d968397 Mon Sep 17 00:00:00 2001 From: Chris Lumens Date: Mon, 1 Jun 2009 16:23:43 -0400 Subject: Fix an error when editing an unreachable repo (#503454). In certain cases, calling getRepo on "InstallationRepo" causes a RepoError. When we catch that, we don't set the repo value to anything, so a traceback results. Instead we need to fix the fix for creating a new repo. --- yuminstall.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'yuminstall.py') diff --git a/yuminstall.py b/yuminstall.py index e7f1d915d..34e3c1859 100644 --- a/yuminstall.py +++ b/yuminstall.py @@ -473,8 +473,9 @@ class AnacondaYum(YumSorter): repo.baseurl = uri except RepoError: replace = False - else: - # If there was an error finding the "base" repo, create a new one now. + + # If there was an error finding the "base" repo, create a new one now. + if not replace: repo = AnacondaYumRepo("anaconda-%s-%s" % (rid, productStamp)) repo.baseurl = uri -- cgit