[yum-commits] Branch 'yum-3_2_X' - yummain.py yum/plugins.py

Ville Skyttä scop at osuosl.org
Thu Apr 7 17:36:44 UTC 2011


 yum/plugins.py |    5 ++---
 yummain.py     |    2 +-
 2 files changed, 3 insertions(+), 4 deletions(-)

New commits:
commit 9ad60ef3dc040434ce2137a03d82fe0fed232a95
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Thu Apr 7 20:34:49 2011 +0300

    Revert "Allow plugins to signal exit status, bump plugin API version to 2.7."
    
    This reverts commit d14bdfe42073859f4c28476e4394e466047c3bfb.
    
    (Accidentally pushed from wrong local branch, oops.)

diff --git a/yum/plugins.py b/yum/plugins.py
index eecaa22..bfc49b7 100644
--- a/yum/plugins.py
+++ b/yum/plugins.py
@@ -63,7 +63,7 @@ from yum.i18n import utf8_width
 # API, the major version number must be incremented and the minor version number
 # reset to 0. If a change is made that doesn't break backwards compatibility,
 # then the minor number must be incremented.
-API_VERSION = '2.7'
+API_VERSION = '2.6'
 
 class DeprecatedInt(int):
     '''
@@ -107,10 +107,9 @@ SLOTS = sorted(SLOT_TO_CONDUIT.keys())
 class PluginYumExit(Exception):
     '''Used by plugins to signal that yum should stop
     '''
-    def __init__(self, value="", translation_domain="", exitstatus=1):
+    def __init__(self, value="", translation_domain=""):
         self.value = value
         self.translation_domain = translation_domain
-        self.exitstatus = exitstatus
     def __str__(self):
         if self.translation_domain:
             return gettext.dgettext(self.translation_domain, self.value)
diff --git a/yummain.py b/yummain.py
index beb1267..1b94153 100755
--- a/yummain.py
+++ b/yummain.py
@@ -61,7 +61,7 @@ def main(args):
         if exitmsg:
             logger.warn('\n\n%s', exitmsg)
         if unlock(): return 200
-        return e.exitstatus
+        return 1
 
     def exFatal(e):
         logger.critical('\n\n%s', exception2msg(e.value))


More information about the Yum-commits mailing list