[master/f24/rhel7-branch] Add device id to dasdfmt screen. (#1269174)
by Samantha N. Bueno
Since device id's do not always map to device names as expected
(e.g. dasda -> 0.0.0200, dasdb -> 0.0.0201, etc.), include the device
id on the dasdfmt screen so that it's clear which devices are going to
be formatted.
This required a couple of changes to the storage spoke as well since we
were only passing a list of device names to the dasdfmt dialog; now it
passes a list of DASDDevice objects, so the dasdfmt dialog can access
the device id attr.
See: https://sbueno.fedorapeople.org/1269174.png
(Although, only one space between devname and devid, not two.)
Resolves: rhbz#1269174
---
pyanaconda/ui/gui/spokes/lib/dasdfmt.py | 6 +++---
pyanaconda/ui/gui/spokes/storage.py | 7 +++++--
2 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/lib/dasdfmt.py b/pyanaconda/ui/gui/spokes/lib/dasdfmt.py
index e1d3df2..6f31570 100644
--- a/pyanaconda/ui/gui/spokes/lib/dasdfmt.py
+++ b/pyanaconda/ui/gui/spokes/lib/dasdfmt.py
@@ -56,7 +56,7 @@ class DasdFormatDialog(GUIObject):
self._hub_label = self.builder.get_object("returnToHubLabel1")
if len(self.to_format) > 0:
- self._unformatted_label.set_text("\n".join("/dev/" + d for d in to_format))
+ self._unformatted_label.set_text("\n".join("/dev/" + d.name + " (" + d.busid + ")" for d in to_format))
else:
self._unformatted_label.set_text("")
@@ -90,8 +90,8 @@ class DasdFormatDialog(GUIObject):
""" Loop through our disks and run dasdfmt against them. """
for disk in self.to_format:
try:
- gtk_call_once(self._formatting_label.set_text, _("Formatting /dev/%s. This may take a moment.") % disk)
- format_dasd(disk)
+ gtk_call_once(self._formatting_label.set_text, _("Formatting /dev/%s. This may take a moment.") % disk.name)
+ format_dasd(disk.name)
except DasdFormatError as err:
# Log errors if formatting fails, but don't halt the installer
log.error(str(err))
diff --git a/pyanaconda/ui/gui/spokes/storage.py b/pyanaconda/ui/gui/spokes/storage.py
index c6751fb..4e3eb81 100644
--- a/pyanaconda/ui/gui/spokes/storage.py
+++ b/pyanaconda/ui/gui/spokes/storage.py
@@ -839,10 +839,13 @@ class StorageSpoke(NormalSpoke, StorageChecker):
# check for unformatted DASDs and launch dasdfmt if any discovered
dasds = make_unformatted_dasd_list(self.selected_disks)
if len(dasds) > 0:
+ # need to get a list of DASDDevice objects, so....
+ dasdobjs = [self.storage.devicetree.getDeviceByName(d) for d in dasds]
+
# We want to apply current selection before running dasdfmt to
# prevent this information from being lost afterward
applyDiskSelection(self.storage, self.data, self.selected_disks)
- dialog = DasdFormatDialog(self.data, self.storage, dasds)
+ dialog = DasdFormatDialog(self.data, self.storage, dasdobjs)
ignoreEscape(dialog.window)
rc = self.run_lightbox_dialog(dialog)
if rc == 1:
@@ -860,7 +863,7 @@ class StorageSpoke(NormalSpoke, StorageChecker):
return
# check for ldl dasds
- ldldasds = [d.name for d in self.storage.devicetree.dasd if is_ldl_dasd(d.name)]
+ ldldasds = [d for d in self.storage.devicetree.dasd if is_ldl_dasd(d.name)]
if len(ldldasds) > 0:
dialog = DasdFormatDialog(self.data, self.storage, ldldasds)
ignoreEscape(dialog.window)
--
2.4.3
8 years, 2 months
[masater/f24/rhel7-branch] Unify displayed columns in custom spoke dialogs. (#1289577)
by Samantha N. Bueno
"Selected disks", "configure mountpoint", and "configure volume group"
now show all the same information. Was "ID" ever a useful column to show
in "configure volume group"? It seems like enough useful info to distinguish
devices can be found from just device description, etc.
So removed "ID" column from "configure volume group" and added "Name"
column. Also changed "Disk" -> "Description" (since that's what is shown).
You can see the before/after here:
http://sbueno.fedorapeople.org/1289577-before.png
http://sbueno.fedorapeople.org/1289577-after.jpg
Resolves: rhbz#12289577
---
.../ui/gui/spokes/lib/custom_storage_helpers.glade | 26 +++++++++++-----------
.../ui/gui/spokes/lib/custom_storage_helpers.py | 2 +-
2 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.glade b/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.glade
index af20996..0b2119d 100644
--- a/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.glade
+++ b/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.glade
@@ -712,7 +712,7 @@ use. Try something else?</property>
<child>
<object class="GtkTreeViewColumn" id="disk_column1">
<property name="spacing">6</property>
- <property name="title" translatable="yes">Disk</property>
+ <property name="title" translatable="yes">Description</property>
<property name="clickable">True</property>
<child>
<object class="GtkCellRendererText" id="disk_renderer1"/>
@@ -723,40 +723,40 @@ use. Try something else?</property>
</object>
</child>
<child>
- <object class="GtkTreeViewColumn" id="capacity_column1">
+ <object class="GtkTreeViewColumn" id="name_column1">
<property name="spacing">6</property>
- <property name="title" translatable="yes">Capacity</property>
+ <property name="title" translatable="yes">Name</property>
<property name="clickable">True</property>
<child>
- <object class="GtkCellRendererText" id="capacity_renderer1"/>
+ <object class="GtkCellRendererText" id="name_renderer1"/>
<attributes>
- <attribute name="text">1</attribute>
+ <attribute name="text">3</attribute>
</attributes>
</child>
</object>
</child>
<child>
- <object class="GtkTreeViewColumn" id="free_column1">
+ <object class="GtkTreeViewColumn" id="capacity_column1">
<property name="spacing">6</property>
- <property name="title" translatable="yes">Free</property>
+ <property name="title" translatable="yes">Capacity</property>
<property name="clickable">True</property>
<child>
- <object class="GtkCellRendererText" id="free_renderer1"/>
+ <object class="GtkCellRendererText" id="capacity_renderer1"/>
<attributes>
- <attribute name="text">2</attribute>
+ <attribute name="text">1</attribute>
</attributes>
</child>
</object>
</child>
<child>
- <object class="GtkTreeViewColumn" id="id_column1">
+ <object class="GtkTreeViewColumn" id="free_column1">
<property name="spacing">6</property>
- <property name="title" translatable="yes">ID</property>
+ <property name="title" translatable="yes">Free</property>
<property name="clickable">True</property>
<child>
- <object class="GtkCellRendererText" id="id_renderer1"/>
+ <object class="GtkCellRendererText" id="free_renderer1"/>
<attributes>
- <attribute name="text">3</attribute>
+ <attribute name="text">2</attribute>
</attributes>
</child>
</object>
diff --git a/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.py b/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.py
index e095fee..8a7ebd0 100644
--- a/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.py
+++ b/pyanaconda/ui/gui/spokes/lib/custom_storage_helpers.py
@@ -476,7 +476,7 @@ class ContainerDialog(GUIObject, GUIDialogInputCheckHandler):
self._store.append([getDiskDescription(disk),
str(disk.size),
str(free[disk.name][0]),
- disk.serial,
+ disk.name,
disk.id])
model = self._treeview.get_model()
--
2.4.3
8 years, 2 months
[rhel7-branch 1/1] Check to see if DD repo is already in addOn list
(#1268357)
by dashea
From: "Brian C. Lane" <bcl(a)redhat.com>
When the repodata was re-downloaded it would add the DD repos again
without checking to see if they were already there.
Resolves: rhbz#1268357
---
pyanaconda/packaging/__init__.py | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/pyanaconda/packaging/__init__.py b/pyanaconda/packaging/__init__.py
index 62d52c0..c7750dd 100644
--- a/pyanaconda/packaging/__init__.py
+++ b/pyanaconda/packaging/__init__.py
@@ -1026,10 +1026,12 @@ def addDriverRepos(self):
log.info("Running createrepo on %s", repo)
iutil.execWithRedirect("createrepo", [repo])
- ks_repo = self.data.RepoData(name="DD-%d" % dir_num,
- baseurl="file://"+repo,
- enabled=True)
- self.addRepo(ks_repo)
+ repo_name = "DD-%d" % dir_num
+ if repo_name not in self.addOns:
+ ks_repo = self.data.RepoData(name=repo_name,
+ baseurl="file://"+repo,
+ enabled=True)
+ self.addRepo(ks_repo)
# Add packages
if not os.path.exists("/run/install/dd_packages"):
--
To view this commit on github, visit https://github.com/rhinstaller/anaconda/commit/70b6fcdac450e9646699ce3da4...
8 years, 2 months
[master 1/1] Add glibc-all-langpacks
by dashea
From: David Shea <dshea(a)redhat.com>
glibc recently split all of its locale data into subpackages, so if we
install no langpacks we get no locales. Explicitly install all of the
langpacks.
---
share/templates.d/99-generic/runtime-install.tmpl | 3 +++
1 file changed, 3 insertions(+)
diff --git a/share/templates.d/99-generic/runtime-install.tmpl b/share/templates.d/99-generic/runtime-install.tmpl
index 27bfca0..8ba0e71 100644
--- a/share/templates.d/99-generic/runtime-install.tmpl
+++ b/share/templates.d/99-generic/runtime-install.tmpl
@@ -24,6 +24,9 @@ installpkg grubby
installpkg b43-openfwwf
%endif
+## install all of the glibc langpacks since otherwise we get no locales
+installpkg glibc-all-langpacks
+
## arch-specific packages (bootloaders etc.)
%if basearch == "aarch64":
installpkg efibootmgr grub2-efi grub2-efi-modules grubby shim shim-unsigned
--
To view this commit on github, visit https://github.com/rhinstaller/lorax/commit/0dd3b9454ddde6597550003a6d5b4...
8 years, 2 months