In some cases (especially on distro upgrades where you have to do
further updates after the fact), loading plugins can fail to load for
various reasons. We should probably be tolerant of that and just not
load them. What do people think of the attached?
Jeremy
Index: yum/plugins.py
===================================================================
RCS file: /home/groups/yum/cvs/yum/yum/plugins.py,v
retrieving revision 1.40
diff -u -u -r1.40 plugins.py
--- yum/plugins.py 5 Jun 2007 07:52:58 -0000 1.40
+++ yum/plugins.py 13 Jun 2007 18:41:21 -0000
@@ -196,6 +196,9 @@
fp, pathname, description = imp.find_module(modname, [dir])
try:
module = imp.load_module(modname, fp, pathname, description)
+ except ImportError:
+ self.verbose_logger.debug('"%s" plugin failed to load; disabling', modname)
+ return
finally:
fp.close()
_______________________________________________
Yum-devel mailing list
[email protected]
https://lists.dulug.duke.edu/mailman/listinfo/yum-devel