Fix epkginfo to not traceback if herds.xml is not in the tree
authorfuzzyray <fuzzyray@gentoo.org>
Fri, 8 Jan 2010 21:38:33 +0000 (21:38 -0000)
committerfuzzyray <fuzzyray@gentoo.org>
Fri, 8 Jan 2010 21:38:33 +0000 (21:38 -0000)
svn path=/trunk/gentoolkit/; revision=732

ChangeLog
pym/gentoolkit/metadata.py

index 85f41f858b5453a7af7d9b30baf0930bb145e3aa..c68aef3b6d5b668d8672ceb096c2df8312eca329 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-01-08: Paul Varner <fuzzyray@gentoo.org>
+       * epkginfo/equery: Fix expkinfo to not traceback if herds.xml is not
+       present in the tree. (Bug 300108)
+
 2009-12-17: Paul Varner <fuzzyray@gentoo.org>
        * revdep-rebuild: Fix revdep-rebuild to properly honor
        PORTAGE_NICENESS as an incremental to the current nice level (Bug
index 02fe03fb8d2d185f0988dc6019c590090960353c..33fdcaf4cef359bd8268de24c8c3d310502a9ba0 100644 (file)
@@ -205,7 +205,10 @@ class MetaData(object):
 
                if self._herdstree is None:
                        herds_path = os.path.join(settings['PORTDIR'], 'metadata/herds.xml')
-                       self._herdstree = etree.parse(herds_path)
+                       try:
+                               self._herdstree = etree.parse(herds_path)
+                       except IOError:
+                               return None
 
                # Some special herds are not listed in herds.xml
                if herd in ('no-herd', 'maintainer-wanted', 'maintainer-needed'):