dabo Commit
Revision 5131
Date: 2009-03-15 10:35:36 -0700 (Sun, 15 Mar 2009)
Author: Ed
Trac: http://trac.dabodev.com/changeset/5131
Changed:
U trunk/dabo/lib/xmltodict.py
Log:
Fixed the missing exception info noted by Carl Karsten when parsing XML strings
instead of XML files.
Diff:
Modified: trunk/dabo/lib/xmltodict.py
===================================================================
--- trunk/dabo/lib/xmltodict.py 2009-03-15 17:34:13 UTC (rev 5130)
+++ trunk/dabo/lib/xmltodict.py 2009-03-15 17:35:36 UTC (rev 5131)
@@ -202,10 +202,10 @@
# argument must have been raw xml:
try:
ret = parser.Parse(xml)
- except expat.ExpatError:
- errmsg = _("An invalid XML string was encountered")
+ except expat.ExpatError, e:
+ errmsg = _("An invalid XML string was encountered: %s")
% e
if errmsg:
- raise dabo.dException.XmlException, errmsg
+ raise dabo.dException.XmlException(errmsg)
if addCodeFile and isPath:
# Get the associated code file, if any
codePth = "%s-code.py" % os.path.splitext(xml)[0]
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message:
http://leafe.com/archives/byMID/[email protected]