summaryrefslogtreecommitdiffstats
path: root/packages.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2009-10-15 12:01:06 -0400
committerChris Lumens <clumens@redhat.com>2009-10-15 12:01:06 -0400
commit2b57b826afb457f5d0cd23743db6a3d2ccb722a0 (patch)
tree81e33081c0f0e91220e0435d20aec79d4bdc7877 /packages.py
parent770a67a2702b92db1983f1a9baa73a8a0ea3e168 (diff)
downloadanaconda-2b57b826afb457f5d0cd23743db6a3d2ccb722a0.tar.gz
anaconda-2b57b826afb457f5d0cd23743db6a3d2ccb722a0.tar.xz
anaconda-2b57b826afb457f5d0cd23743db6a3d2ccb722a0.zip
Add a "File Bug" button to all possibilitys in turnOnFilesystems (#528006).
Diffstat (limited to 'packages.py')
-rw-r--r--packages.py93
1 files changed, 39 insertions, 54 deletions
diff --git a/packages.py b/packages.py
index bd9445ecc..783d2ad69 100644
--- a/packages.py
+++ b/packages.py
@@ -106,77 +106,62 @@ def turnOnFilesystems(anaconda):
if d.format.migrate:
upgrade_migrate = True
+ title = None
+ message = None
+ details = None
+
try:
anaconda.id.storage.doIt()
except DeviceResizeError as (msg, device):
# XXX does this make any sense? do we support resize of
# devices other than partitions?
- anaconda.intf.detailedMessageWindow(_("Device Resize Failed"),
- _("An error was encountered while "
- "resizing device %s.") % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Device Resize Failed")
+ message = _("An error was encountered while "
+ "resizing device %s.") % (device,)
+ details = msg
except DeviceCreateError as (msg, device):
- anaconda.intf.detailedMessageWindow(_("Device Creation Failed"),
- _("An error was encountered while "
- "creating device %s.") % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Device Creation Failed")
+ message = _("An error was encountered while "
+ "creating device %s.") % (device,)
+ details = msg
except DeviceDestroyError as (msg, device):
- anaconda.intf.detailedMessageWindow(_("Device Removal Failed"),
- _("An error was encountered while "
- "removing device %s.") % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Device Removal Failed")
+ message = _("An error was encountered while "
+ "removing device %s.") % (device,)
+ details = msg
except DeviceError as (msg, device):
- anaconda.intf.detailedMessageWindow(_("Device Setup Failed"),
- _("An error was encountered while "
- "setting up device %s.") % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Device Setup Failed")
+ message = _("An error was encountered while "
+ "setting up device %s.") % (device,)
+ details = msg
except FSResizeError as (msg, device):
+ title = _("Resizing Failed")
+ message = _("There was an error encountered while "
+ "resizing the device %s.") % (device,)
+
if os.path.exists("/tmp/resize.out"):
details = open("/tmp/resize.out", "r").read()
else:
details = "%s" %(msg,)
- anaconda.intf.detailedMessageWindow(_("Resizing Failed"),
- _("There was an error encountered while "
- "resizing the device %s.") %(device,),
- details,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
except FSMigrateError as (msg, device):
- anaconda.intf.detailedMessageWindow(_("Migration Failed"),
- _("An error was encountered while "
- "migrating filesystem on device %s.")
- % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Migration Failed")
+ message = _("An error was encountered while "
+ "migrating filesystem on device %s.") % (device,)
+ details = msg
except FormatCreateError as (msg, device):
- anaconda.intf.detailedMessageWindow(_("Formatting Failed"),
- _("An error was encountered while "
- "formatting device %s.") % (device,),
- msg,
- type = "custom",
- custom_buttons = [_("_Exit installer")])
- sys.exit(1)
+ title = _("Formatting Failed")
+ message = _("An error was encountered while "
+ "formatting device %s.") % (device,)
+ details = msg
except Exception as msg:
# catch-all
- rc = anaconda.intf.detailedMessageWindow(_("Storage Activation Failed"),
- _("An error was encountered while "
- "activating your storage configuration."),
- msg,
+ title = _("Storage Activation Failed")
+ message = _("An error was encountered while "
+ "activating your storage configuration.")
+ details = msg
+
+ if title:
+ rc = anaconda.intf.detailedMessageWindow(title, message, details,
type = "custom",
custom_buttons = [_("_File Bug"), _("_Exit installer")])