[GRASS-SVN] r54736 - grass/branches/releasebranch_6_4/gui/scripts
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Jan 21 09:58:20 PST 2013
Author: martinl
Date: 2013-01-21 09:58:20 -0800 (Mon, 21 Jan 2013)
New Revision: 54736
Modified:
grass/branches/releasebranch_6_4/gui/scripts/g.extension.py
Log:
g.extension: fix installation process when metadata file is broken or not available
(merge r54735 from devbr6)
Modified: grass/branches/releasebranch_6_4/gui/scripts/g.extension.py
===================================================================
--- grass/branches/releasebranch_6_4/gui/scripts/g.extension.py 2013-01-21 17:55:55 UTC (rev 54735)
+++ grass/branches/releasebranch_6_4/gui/scripts/g.extension.py 2013-01-21 17:58:20 UTC (rev 54736)
@@ -356,7 +356,12 @@
data = None
try:
f = urlopen(url)
- tree = etree.fromstring(f.read())
+ try:
+ tree = etree.fromstring(f.read())
+ except:
+ grass.warning(_("Unable to parse '%s'. Metadata file not updated.") % url)
+ return
+
for mnode in tree.findall('task'):
name = mnode.get('name')
if name != options['extension']:
More information about the grass-commit
mailing list