classification
Title: cElementTree & ElementTree use different exceptions for XML Errors
Type: behavior Stage: resolved
Components: Versions: Python 3.1, Python 3.2, Python 2.7, Python 2.6
process
Status: closed Resolution: fixed
Dependencies: Superseder: Update ElementTree with upstream changes
View: 6472
Assigned To: Nosy List: Neil Muller, effbot, flox, jerith
Priority: normal Keywords:

Created on 2009-06-11 10:46 by Neil Muller, last changed 2010-03-11 15:00 by flox. This issue is now closed.

Messages (2)
msg89247 - (view) Author: Neil Muller (Neil Muller) Date: 2009-06-11 10:46
cElementTree will raise a SyntaxError on XML parsing errors, while
ElementTree will raise ExpatError.  This makes changing between the two
a bit more problematic than it could be. See for example
https://lists.canonical.com/archives/bazaar/2006q3/017491.html

ElementTree 1.3 raises a ParseError, which is subclassed from
SyntaxError, which will improve the situation when it's merged, but
cElementTree should be adjusted to raise the same error.
msg99406 - (view) Author: Florent Xicluna (flox) * (Python committer) Date: 2010-02-16 13:13
Should be fixed with upstream ElementTree 1.3/cElementTree 1.0.6.

See issue #6472.
History
Date User Action Args
2010-03-11 15:00:15floxsetstatus: open -> closed
resolution: fixed
dependencies: - Update ElementTree with upstream changes
superseder: Update ElementTree with upstream changes
stage: resolved
2010-02-16 13:13:41floxsetpriority: normal

nosy: + flox
messages: + msg99406

dependencies: + Update ElementTree with upstream changes
type: behavior
2009-06-11 10:46:46Neil Mullercreate