[PATCH] display storage errors in text mode storage spoke
by Brian C. Lane
From: "Brian C. Lane" <bcl(a)redhat.com>
---
pyanaconda/ui/tui/spokes/storage.py | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/ui/tui/spokes/storage.py b/pyanaconda/ui/tui/spokes/storage.py
index c0a7cdd..a8b3d9f 100644
--- a/pyanaconda/ui/tui/spokes/storage.py
+++ b/pyanaconda/ui/tui/spokes/storage.py
@@ -168,6 +168,10 @@ class StorageSpoke(NormalTUISpoke):
elif count == 0:
summary = (_("No disks selected; please select at least one disk to install to."))
+ # Append storage errors to the summary
+ if self.errors:
+ summary = summary + "\n" + "\n".join(self.errors)
+
return summary
def refresh(self, args = None):
@@ -261,7 +265,8 @@ class StorageSpoke(NormalTUISpoke):
doKickstartStorage(self.storage, self.data, self.instclass)
except StorageError as e:
log.error("storage configuration failed: %s" % e)
- self.errors = e
+ print _("storage configuration failed: %s") % e
+ self.errors = [str(e)]
self.data.clearpart.type = CLEARPART_TYPE_ALL
self.data.clearpart.initAll = False
self.storage.config.update(self.data)
@@ -274,8 +279,10 @@ class StorageSpoke(NormalTUISpoke):
self._ready = True
for e in self.errors:
log.error(e)
+ print e
for w in warnings:
log.warn(w)
+ print w
def initialize(self):
NormalTUISpoke.initialize(self)
--
1.7.11.7
11 years, 6 months
[PATCH] Fix a race condition with kickstarts (#868834)
by Jesse Keating
We were simluating the continue click before consuming all the messages
in the queue, which would cause the next hub to be in use, but we were
attempting to process messages for the previous hub. It would cause a
crash of anaconda, but not a backtrace that could be caught with our
autoreporter. The solution is to only continue when the queue is empty.
This also makes use of a property to see if we are ready to continue
instead of duplicating code.
---
pyanaconda/ui/gui/hubs/__init__.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/ui/gui/hubs/__init__.py b/pyanaconda/ui/gui/hubs/__init__.py
index 13f6192..3a88cc3 100644
--- a/pyanaconda/ui/gui/hubs/__init__.py
+++ b/pyanaconda/ui/gui/hubs/__init__.py
@@ -278,11 +278,12 @@ class Hub(GUIObject, common.Hub):
if not args[1]:
spoke.execute()
- if len(self._incompleteSpokes) == 0 and len(self._notReadySpokes) == 0:
+ if self.continuePossible:
if self._inSpoke:
self._autoContinue = True
else:
- self.continueButton.emit("clicked")
+ if q.empty():
+ self.continueButton.emit("clicked")
elif code == communication.HUB_CODE_MESSAGE:
spoke.selector.set_property("status", args[1])
--
1.7.11.4
11 years, 6 months
[PATCH] /etc/sysconfig/keyboard doesn't support vconsole.xyz options.
by Bill Nottingham
---
pyanaconda/keyboard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/keyboard.py b/pyanaconda/keyboard.py
index 51d3959..5aa9c5d 100755
--- a/pyanaconda/keyboard.py
+++ b/pyanaconda/keyboard.py
@@ -187,7 +187,7 @@ def write_keyboard_config(keyboard, root, convert=True, weight=0):
if keyboard.vc_keymap:
try:
with open(os.path.join(sysconf_dir, sysconf_file), "w") as fobj:
- fobj.write('vconsole.keymap="%s"\n' % keyboard.vc_keymap)
+ fobj.write('KEYMAP="%s"\n' % keyboard.vc_keymap)
except IOError as ioerr:
errors.append("Cannot write sysconfig keyboard configuration file")
--
1.7.12.1
11 years, 6 months
[rhel6-branch] [PATCH] Add Microsoft PV drivers (#834689)
by Vratislav Podzimek
Signed-off-by: Vratislav Podzimek <vpodzime(a)redhat.com>
---
scripts/mk-images | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/mk-images b/scripts/mk-images
index 5fb5a29..2a89ce4 100755
--- a/scripts/mk-images
+++ b/scripts/mk-images
@@ -113,7 +113,9 @@ CRYPTOMODS="sha256_generic cbc xts lrw aes_generic crypto_blkcipher crc32c ecb a
PCMCIASOCKMODS="yenta_socket i82365 tcic pcmcia"
INFINIBANDMODS="ib_qib mlx4_ib"
VMPVMODS="vmxnet3 vmware_balloon vmw_pvsci"
-INITRDMODS="$USBMODS $FIREWIREMODS $IDEMODS $SCSIMODS $FSMODS $LVMMODS $RAIDMODS $CRYPTOMODS $COMMONMODS $PCMCIASOCKMODS $INFINIBANDMODS $SDMODS $VMPVMODS =scsi =net =drm"
+MSPVMODS="hv_storvsc hid_hyperv hv_netvsc hv_vmbus hv_util ata_piix"
+INITRDMODS="$USBMODS $FIREWIREMODS $IDEMODS $SCSIMODS $FSMODS $LVMMODS $RAIDMODS $CRYPTOMODS $COMMONMODS \
+ $PCMCIASOCKMODS $INFINIBANDMODS $SDMODS $VMPVMODS $MSPVMODS =scsi =net =drm"
. $(dirname $0)/buildinstall.functions
--
1.7.11.7
11 years, 6 months
Re: Re: [PATCH] Add PowerNV as a recognized PPC platform
by Mark Hamzy
> On Thu, 2012-10-25 at 10:05:46 +0200, vpodzime(a)redhat.com wrote:
> Looks good to me. Mark, could you please review the patch and push it if
> it seems okay to you?
It looks good to me, Vratislav. Can you push both patches into master and
F18? I have no powers. :)
Mark
11 years, 6 months
[PATCH] Use a slightly different method to get supported languages (#858801, tagoh).
by Chris Lumens
---
pyanaconda/localization.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/localization.py b/pyanaconda/localization.py
index 47f4e01..d7c332c 100644
--- a/pyanaconda/localization.py
+++ b/pyanaconda/localization.py
@@ -154,8 +154,8 @@ def get_available_translations(domain=None, localedir=None):
domain = domain or gettext._current_domain
localedir = localedir or gettext._default_localedir
- langdict = babel.Locale('en', 'US').languages
- messagefiles = gettext.find(domain, localedir, langdict.keys(), all=True)
+ langdict = babel.localedata.list()
+ messagefiles = gettext.find(domain, localedir, langdict, all=True)
languages = [path.split(os.path.sep)[-3] for path in messagefiles]
# usually there are no message files for en
--
1.7.11.2
11 years, 6 months
[master] [PATCH] Toggle chosen property on focus change (MountpointSelector)
by Vratislav Podzimek
Resolves: rhbz#869388
Signed-off-by: Vratislav Podzimek <vpodzime(a)redhat.com>
---
widgets/src/MountpointSelector.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/widgets/src/MountpointSelector.c b/widgets/src/MountpointSelector.c
index a3904d3..cf62d06 100644
--- a/widgets/src/MountpointSelector.c
+++ b/widgets/src/MountpointSelector.c
@@ -298,9 +298,11 @@ static gboolean anaconda_mountpoint_selector_focus_changed(GtkWidget *widget, Gd
if (event->in) {
gtk_widget_show(GTK_WIDGET(ANACONDA_MOUNTPOINT_SELECTOR(widget)->priv->arrow));
new_state |= GTK_STATE_FOCUSED;
+ anaconda_mountpoint_selector_set_chosen(ANACONDA_MOUNTPOINT_SELECTOR(widget), TRUE);
}
else {
gtk_widget_hide(GTK_WIDGET(ANACONDA_MOUNTPOINT_SELECTOR(widget)->priv->arrow));
+ anaconda_mountpoint_selector_set_chosen(ANACONDA_MOUNTPOINT_SELECTOR(widget), FALSE);
}
gtk_widget_set_state_flags(widget, new_state, TRUE);
--
1.7.11.7
11 years, 6 months
[PATCH] Add PowerNV as a recognized PPC platform
by Nishanth Aravamudan
When running a suitable POWER machine in PowerNV mode,
the Platform in /proc/cpuinfo is reported as "PowerNV".
This causes Anaconda to fail the installation due to an
unrecognized platform. Add "PowerNV" as an alias of "pSeries"
for now.
Signed-off-by: Nishanth Aravamudan <nacc(a)us.ibm.com>
diff --git a/pyanaconda/iutil.py b/pyanaconda/iutil.py
index 730da8c..7e096f5 100644
--- a/pyanaconda/iutil.py
+++ b/pyanaconda/iutil.py
@@ -548,7 +548,8 @@ def getPPCMachine():
'Maple' : 'pSeries',
'Cell' : 'pSeries',
'Momentum' : 'pSeries',
- 'PS3' : 'PS3'
+ 'PS3' : 'PS3',
+ 'PowerNV' : 'pSeries'
}
f = open('/proc/cpuinfo', 'r')
11 years, 6 months
[master] [PATCH] anaconda should print unknown platform information
by Mark Hamzy
869746: Include more information as part of the system error.
---
pyanaconda/platform.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/platform.py b/pyanaconda/platform.py
index 8fade39..64b9cc8 100644
--- a/pyanaconda/platform.py
+++ b/pyanaconda/platform.py
@@ -394,7 +394,7 @@ def getPlatform():
elif ppcMachine == "PS3":
return PS3()
else:
- raise SystemError, "Unsupported PPC machine type"
+ raise SystemError, "Unsupported PPC machine type: %s" % ppcMachine
elif iutil.isS390():
return S390()
elif iutil.isSparc():
--
1.7.11.2
11 years, 6 months
[PATCH 1/2] Tie "Reclaim Space" button sensitivity to how much space the user freed (#869375).
by Chris Lumens
---
pyanaconda/ui/gui/spokes/lib/resize.glade | 1 +
pyanaconda/ui/gui/spokes/lib/resize.py | 9 ++++++++-
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/lib/resize.glade b/pyanaconda/ui/gui/spokes/lib/resize.glade
index 15f90af..e3aa001 100644
--- a/pyanaconda/ui/gui/spokes/lib/resize.glade
+++ b/pyanaconda/ui/gui/spokes/lib/resize.glade
@@ -72,6 +72,7 @@
<object class="GtkButton" id="resizeButton">
<property name="label" translatable="yes">_Reclaim space</property>
<property name="visible">True</property>
+ <property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="halign">end</property>
diff --git a/pyanaconda/ui/gui/spokes/lib/resize.py b/pyanaconda/ui/gui/spokes/lib/resize.py
index 3781807..19d16e3 100644
--- a/pyanaconda/ui/gui/spokes/lib/resize.py
+++ b/pyanaconda/ui/gui/spokes/lib/resize.py
@@ -61,6 +61,7 @@ class ResizeDialog(GUIObject):
def __init__(self, data, storage, payload):
GUIObject.__init__(self, data)
self.storage = storage
+ self.payload = payload
self._actionStore = self.builder.get_object("actionStore")
self._diskStore = self.builder.get_object("diskStore")
@@ -72,10 +73,12 @@ class ResizeDialog(GUIObject):
self._required_label = self.builder.get_object("requiredSpaceLabel")
markup = self._required_label.get_label()
- self._required_label.set_markup(markup % size_str(payload.spaceRequired))
+ self._required_label.set_markup(markup % size_str(self.payload.spaceRequired))
self._reclaimDescLabel = self.builder.get_object("reclaimDescLabel")
+ self._resizeButton = self.builder.get_object("resizeButton")
+
def _description(self, part):
# First, try to find the partition in some known Root. If we find
# it, return the mountpoint as the description.
@@ -224,6 +227,10 @@ class ResizeDialog(GUIObject):
self._diskStore.foreach(self._sumReclaimableSpace, None)
self._update_labels(selectedReclaimable=self._selectedReclaimableSpace)
+ got = Size(spec="%s MB" % self._selectedReclaimableSpace)
+ need = self.payload.spaceRequired
+ self._resizeButton.set_sensitive(got >= need)
+
def _scheduleActions(self, model, path, itr, *args):
(editable, action, ident) = model.get(itr, EDITABLE_COL, ACTION_COL, DEVICE_ID_COL)
--
1.7.11.2
11 years, 6 months