[libblockdev 0/4] Would like to use scons instead of make
by Anne Mulhern
The primary motivation is that it may make the configuration part, which
would otherwise be handle by autotools, easier. Also, it may actually be
the case that scons is better. I've never written an SConstruct file before
and the whole thing was surprisingly easy. The fact that the file is actually
python is nice, and the automatic, and hopefully correct, handling of C
dependencies is nice too.
One thing that confused me is scons -c (for clean). It cleans for the
default target, only. I don't yet know how to clean for all targets,
without specifying them all, or temporarily removing the default target.
The first patch is just a tiny fix I happened to notice.
Removing the Makefile may seem harsh, but we don't want two build systems
going at once. If we need it back, because this does not work out,
it's not hard to find.
mulhern (4):
Do not add some redundant const modifiers.
Add an SConstruct file largely equivalent to existing Makefile.
Update .gitignore for scons related files.
Remove Makefile to avoid duplicate updates.
.gitignore | 2 +
Makefile | 127 -------------------------------------
SConstruct | 162 +++++++++++++++++++++++++++++++++++++++++++++++
boilerplate_generator.py | 4 +-
4 files changed, 166 insertions(+), 129 deletions(-)
delete mode 100644 Makefile
create mode 100644 SConstruct
--
1.9.3
9 years, 11 months
[PATCH] Run anaconda in fullscreen whenever possible.
by David Shea
Start anaconda in fullscreen mode. If a user unfullscreens the window it
will be decorated, and if the window is later maximized it will be
fullscreened again.
---
pyanaconda/ui/gui/__init__.py | 21 ++++++++++++++++++---
1 file changed, 18 insertions(+), 3 deletions(-)
diff --git a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
index 7055414..ecc12d5 100644
--- a/pyanaconda/ui/gui/__init__.py
+++ b/pyanaconda/ui/gui/__init__.py
@@ -268,9 +268,12 @@ class MainWindow(Gtk.Window):
self._accel_group = Gtk.AccelGroup()
self.add_accel_group(self._accel_group)
- # Set properties on the window
- self.set_decorated(False)
- self.maximize()
+ # Connect to window-state-event changes to catch when the user
+ # maxmizes/unmaximizes the window.
+ self.connect("window-state-event", self._on_window_state_event)
+
+ # Start the window as full screen
+ self.fullscreen()
self._overlay.add(self._stack)
self.add(self._overlay)
@@ -278,6 +281,18 @@ class MainWindow(Gtk.Window):
self._current_action = None
+ def _on_window_state_event(self, window, event, user_data=None):
+ # If the window is being maximized, fullscreen it instead
+ if (Gdk.WindowState.MAXIMIZED & event.changed_mask) and \
+ (Gdk.WindowState.MAXIMIZED & event.new_window_state):
+ self.fullscreen()
+
+ # Return true to stop the signal handler since we're changing
+ # state mid-stream here
+ return True
+
+ return False
+
def _on_delete_event(self, widget, event, user_data=None):
# Use the quit-clicked signal on the the current standalone, even if the
# standalone is not currently displayed.
--
2.0.0
9 years, 11 months
[blivet] small patches for partitioning
by David Lehman
Patch 1 means that kickstart with multiple growable requests could end
up with some unusable results due to all requests thinking they're
entitled to 0% of the free sectors in the chunk/disk. Float would probably
suffice since it's only calculating a percentage, but using Decimal has
become a habit.
Patches 2 and 3 are minor bugs I noticed when doing some other work.
Patch 4 has been sitting on the shelf for a couple of months for no real
reason.
David Lehman (4):
Don't use integer division to calculate a fraction.
A Chunk is done growing when its pool is empty.
Honor the skip list when allocating leftover sectors.
Add some tests for Chunk and Request class hierarchy.
blivet/partitioning.py | 7 ++-
tests/partitioning_test.py | 138 +++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 142 insertions(+), 3 deletions(-)
--
1.9.3
9 years, 11 months
[blivet:master 00/13] rhbz#1070095 related patches (v4)
by Anne Mulhern
This patch set is definitely converging.
Change uuid parameter...new, trivial.
Use context manager with assertRaises*...new, busy, but mechanical.
...
Add documentation to udev.device_get_md_*() methods...new.
All others are just the same or changed only as requested, so I'm not
re-sending.
mulhern (13):
Change uuid parameter to array_uuid
Use context manager with assertRaises*() tests.
Add test for raid level descriptor None.
Add a few small tests for mdexamine
Document udev.device_get_uuid() method.
Add documentation to udev.device_get_md_*() methods.
Do not convert the result of udev.device_get_md_devices() to int.
Check for md_level of None
Change use of METADATA to MD_METADATA.
Add a udev.device_get_md_metadata() method to udev and use it.
Canonicalize mdadm generated UUIDS (#1070095)
Add new method udev.device_get_md_device_uuid() method (#1070095)
Attempt to reset the uuid of the mdraid member device (#1070095)
blivet/devicelibs/mdraid.py | 30 +++++--
blivet/devices.py | 2 +-
blivet/devicetree.py | 22 +++--
blivet/udev.py | 75 +++++++++++++++++-
tests/devicefactory_test.py | 26 +++---
tests/devicelibs_test/btrfs_test.py | 47 ++++-------
tests/devicelibs_test/crypto_test.py | 74 ++++++-----------
tests/devicelibs_test/lvm_test.py | 96 ++++++++++++----------
tests/devicelibs_test/mdraid_test.py | 113 ++++++++++++++++++++++++--
tests/devicelibs_test/raid_test.py | 39 ++++-----
tests/devicelibs_test/swap_test.py | 15 ++--
tests/devices_test.py | 150 ++++++++++++-----------------------
tests/formats_test/fslabeling.py | 35 ++++----
tests/parentlist_test.py | 6 +-
tests/size_test.py | 3 +-
15 files changed, 429 insertions(+), 304 deletions(-)
--
1.9.3
9 years, 11 months
[PATCH 0/2] Bring back the selection highlight on custom widgets
by David Shea
Hate you, gtk.
David Shea (2):
Restore the bluish background for selected widgets
Correct the constant used with gtk_widget_set_state_flags
data/anaconda-gtk.css | 16 ++++++++++++++++
widgets/src/DiskOverview.c | 4 ++--
widgets/src/SpokeSelector.c | 4 ++--
3 files changed, 20 insertions(+), 4 deletions(-)
--
2.0.0
9 years, 11 months
[lorax] livemedia-creator: Allow the boot.iso to be shared
by Brian C. Lane
This allows the boot.iso to be used by multiple instances of lmc (or
virt-install if they also set --disk shareable=on)
---
src/sbin/livemedia-creator | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/sbin/livemedia-creator b/src/sbin/livemedia-creator
index f055273..be34061 100755
--- a/src/sbin/livemedia-creator
+++ b/src/sbin/livemedia-creator
@@ -339,7 +339,7 @@ class VirtualInstall(object):
args.append(disk_opts)
if iso.liveos:
- disk_opts = "path={0},device=cdrom".format(iso.iso_path)
+ disk_opts = "path={0},device=cdrom,readonly=on,shareable=on".format(iso.iso_path)
args.append("--disk")
args.append(disk_opts)
--
1.9.3
9 years, 11 months
[blivet] two small docs fixes
by David Lehman
David Lehman (2):
Remove spec= from Size usage in intro.rst.
Bump version in sphinx config from scripts/makebumpver.
doc/intro.rst | 6 +++---
scripts/makebumpver | 4 +++-
2 files changed, 6 insertions(+), 4 deletions(-)
--
1.9.3
9 years, 11 months
[master] zRAM swap for the installation
by Vratislav Podzimek
PATCH 2/2 is just a cosmetic change. PATCH 1/2 introduces zRAM used as a swap
device for the installation process. Its commit message should explain more.
Vratislav Podzimek (2):
zRAM swap for Anaconda
Remove extra list() call with no effect
data/systemd/Makefile.am | 3 +-
data/systemd/anaconda.target | 1 +
data/systemd/zram.service | 8 ++++++
pyanaconda/ui/lib/disks.py | 5 ++--
scripts/Makefile.am | 2 +-
scripts/makeupdates | 2 +-
scripts/zramswapoff | 38 +++++++++++++++++++++++++
scripts/zramswapon | 66 ++++++++++++++++++++++++++++++++++++++++++++
8 files changed, 120 insertions(+), 5 deletions(-)
create mode 100644 data/systemd/zram.service
create mode 100755 scripts/zramswapoff
create mode 100755 scripts/zramswapon
--
1.9.3
9 years, 11 months
[PATCH] Decorate the main window when run from outside of the install media.
by David Shea
This means that live/image/dir installs won't get the full screen
anaconda effect, but it also means that when someone unmaximizes the
window during a live/image/dir install that they can still do something
useful with that window.
---
pyanaconda/ui/gui/__init__.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
index 7055414..6bde7a8 100644
--- a/pyanaconda/ui/gui/__init__.py
+++ b/pyanaconda/ui/gui/__init__.py
@@ -27,6 +27,7 @@ from gi.repository import Gdk, Gtk, AnacondaWidgets, Keybinder, GdkPixbuf
from pyanaconda.i18n import _
from pyanaconda import product
+from pyanaconda.flags import flags
from pyanaconda.ui import UserInterface, common
from pyanaconda.ui.gui.utils import gtk_action_wait, busyCursor, unbusyCursor
@@ -269,7 +270,9 @@ class MainWindow(Gtk.Window):
self.add_accel_group(self._accel_group)
# Set properties on the window
- self.set_decorated(False)
+ # Decorate the window if running in someone else's window manager
+ if not flags.imageInstall and not flags.livecdInstall and not flags.dirInstall:
+ self.set_decorated(False)
self.maximize()
self._overlay.add(self._stack)
--
2.0.0
9 years, 11 months
upcoming pylint errors in anaconda
by David Shea
Greetings, people of the past! I come to you with news from the future.
I installed the latest devel version of pylint on my system to work on
what turned into a kind of complicated pull request to catch that
invalid list index thing (which still wouldn't have caught the one we
actually had, sadface), so here is what we can expect in upcoming versions:
pylint reports the following issues:
************* Module pyanaconda/ui/gui/spokes/lib/passphrase.py
W0713:114,30: PassphraseDialog._update_passphrase_strength: Indexing
exceptions will not work on Python 3
************* Module scripts/makebumpver
W0640:241,58: MakeBumpVer._rpmLog.<lambda>: Cell variable commit defined
in loop
************* Module pyanaconda/ui/__init__.py
W0640:179,94: UserInterface._orderActionClasses.<lambda>: Cell variable
hub defined in loop
W0640:182,95: UserInterface._orderActionClasses.<lambda>: Cell variable
hub defined in loop
************* Module pyanaconda/rescue.py
W0703:430,15: doRescue: Catching too general exception Exception
************* Module pyanaconda/users.py
W0713:171,22: validatePassword: Indexing exceptions will not work on
Python 3
************* Module pyanaconda/ui/tui/simpleline/base.py
W0703:286,19: App._do_redraw: Catching too general exception Exception
W0703:345,23: App._mainloop: Catching too general exception Exception
W0703:402,27: App.process_events: Catching too general exception Exception
W0703:440,19: App.input: Catching too general exception Exception
The Indexing exceptions warnings are both on pwquality.PWQError
exceptions, and indexing is the only way we can use them. So if
libpwquality ever supports Python 3, presumably this will change, but
for now we need to just ignore the warnings.
The Cell variable <var> defined in loop are warning us that we're using
a loop variable in a closure, but in all three cases the closure is
within the loop too so who cares.
I guess we might want to do about the Exception ones.
9 years, 11 months