summaryrefslogtreecommitdiffstats
path: root/packages.py
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2004-12-20 23:24:03 +0000
committerJeremy Katz <katzj@redhat.com>2004-12-20 23:24:03 +0000
commit9dc5bcfe99e5af0ab6a53912cde050596f901656 (patch)
treeb7cf98572e3ca066bdf73f97b7480ae37d959308 /packages.py
parent06abe5e6124f25c73fc4e1cbd4500a2bb07ef0d0 (diff)
downloadanaconda-9dc5bcfe99e5af0ab6a53912cde050596f901656.tar.gz
anaconda-9dc5bcfe99e5af0ab6a53912cde050596f901656.tar.xz
anaconda-9dc5bcfe99e5af0ab6a53912cde050596f901656.zip
2004-12-20 Jeremy Katz <katzj@redhat.com>
* packages.py (InstallCallback.cb): Let people reboot more easily in case of bad packages but warn them that it's going to be bad.
Diffstat (limited to 'packages.py')
-rw-r--r--packages.py24
1 files changed, 22 insertions, 2 deletions
diff --git a/packages.py b/packages.py
index a41d373d6..20271c1e8 100644
--- a/packages.py
+++ b/packages.py
@@ -425,7 +425,7 @@ class InstallCallback:
h['release']))
self.method.unmountCD()
- self.messageWindow(_("Error"),
+ rc = self.messageWindow(_("Error"),
_("The package %s-%s-%s cannot be opened. This is due "
"to a missing file or perhaps a corrupt package. "
"If you are installing from CD media this usually "
@@ -433,7 +433,27 @@ class InstallCallback:
"unable to read the media.\n\n"
"Press <return> to try again.") % (h['name'],
h['version'],
- h['release']))
+ h['release']),
+ type="custom",
+ custom_icon="error",
+ custom_buttons = [ _("Re_boot"),
+ _("_Retry") ])
+ if rc == 0:
+ rc = self.messageWindow(_("Warning"),
+ _("If you reboot, your system "
+ "will be left in an "
+ "inconsistent state that "
+ "will likely require "
+ "reinstallation. Are you "
+ "sure you wish to "
+ "continue?"),
+ type = "custom",
+ custom_icon="warning",
+ custom_buttons = [_("_Cancel"),
+ _("_Reboot")])
+ if rc == 1:
+ sys.exit(0)
+
self.progress.setPackageStatus(_("Installing..."), None)
fn = self.method.unlinkFilename(fn)
return self.rpmFD