[node-patches] Change in ovirt-node[master]: ovirt-node-upgrade: catch exceptions that are being skipped ...

jboggs at redhat.com jboggs at redhat.com
Tue May 21 17:35:23 UTC 2013


Joey Boggs has uploaded a new change for review.

Change subject: ovirt-node-upgrade: catch exceptions that are being skipped over
......................................................................

ovirt-node-upgrade: catch exceptions that are being skipped over

Signed-off-by: Joey Boggs <jboggs at redhat.com>
Change-Id: Iefde860477dc21ca231d5dc29d8b79ab364b2c3f
---
M scripts/ovirt-node-upgrade.py
1 file changed, 4 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/58/14958/1

diff --git a/scripts/ovirt-node-upgrade.py b/scripts/ovirt-node-upgrade.py
index fbe7c5f..8fcc372 100755
--- a/scripts/ovirt-node-upgrade.py
+++ b/scripts/ovirt-node-upgrade.py
@@ -297,15 +297,15 @@
             self._run_hooks("post-upgrade")
             if self._options.reboot > 0:
                 self._reboot(self._options.reboot)
-        except:
-            self._logger.error('Error: Upgrade Failed', show_exc=True)
+            self._logger.info("Upgrade Completed")
+            sys.exit(0)
+        except Exception as e:
+            self._logger.exception('Error: Upgrade Failed: %s', e)
             self._run_hooks("rollback")
             self._logger.info("Upgrade Failed, Rollback Completed")
             sys.exit(1)
         finally:
             self._cleanup()
-            self._logger.info("Upgrade Completed")
-            sys.exit(0)
 
 if __name__ == "__main__":
     initLogger()


--
To view, visit http://gerrit.ovirt.org/14958
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iefde860477dc21ca231d5dc29d8b79ab364b2c3f
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Joey Boggs <jboggs at redhat.com>



More information about the node-patches mailing list