-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 ACK. On Wed, 30 Sep 2009, Hans de Goede wrote:
Since the parted ebusy errors due to unnecessary udev event generation on the partition nodes bug has been nailed, we no longer need the retry loop around committing to disk. --- storage/formats/disklabel.py | 23 ++++++----------------- 1 files changed, 6 insertions(+), 17 deletions(-) diff --git a/storage/formats/disklabel.py b/storage/formats/disklabel.py index a387c56..192f1da 100644 --- a/storage/formats/disklabel.py +++ b/storage/formats/disklabel.py @@ -197,23 +197,12 @@ class DiskLabel(DeviceFormat): def commit(self): """ Commit the current partition table to disk and notify the OS. """ - # give committing 5 tries, failing that, raise an exception - attempt = 1 - maxTries = 5 - keepTrying = True - - while keepTrying and (attempt <= maxTries): - try: - self.partedDisk.commit() - keepTrying = False - except parted.DiskException as msg: - log.warning(msg) - attempt += 1 - else: - udev_settle() - - if keepTrying: - raise DeviceFormatError("cannot commit to disk after %d attempts" % (maxTries,), ) + try: + self.partedDisk.commit() + except parted.DiskException as msg: + raise DeviceFormatError(msg) + else: + udev_settle() def commitToDisk(self): """ Commit the current partition table to disk. """
- -- David Cantrell <dcantrell@xxxxxxxxxx>
Red Hat / Honolulu, HI -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkrEIy8ACgkQ5hsjjIy1Vkkm7wCg5eK1dDOQf8WXwtm50rQXccLq 7QwAoMpxFzo6Ef/ZChyI+93ECYckLrar =c1/2 -----END PGP SIGNATURE----- _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list