This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
标题: cElementTree & ElementTree use different exceptions for XML Errors
类型: behavior Stage: resolved
Components: Versions: Python 3.1, Python 3.2, Python 2.7, Python 2.6
process
状态: closed Resolution: fixed
Dependencies: 后续: Update ElementTree with upstream changes
View: 6472
分配给: 抄送列表: Neil Muller, effbot, flox, jerith
优先级: normal 关键字:

Created on 2009-06-11 10:46 by Neil Muller, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg89247 - (view) Author: Neil Muller (Neil Muller) 日期: 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) 日期: 2010-02-16 13:13
Should be fixed with upstream ElementTree 1.3/cElementTree 1.0.6.

See issue #6472.
历史
日期 用户 动作 参数
2022-04-11 14:56:50admin修改github: 50514
2010-03-11 15:00:15flox修改状态: open -> closed
resolution: fixed
dependencies: - Update ElementTree with upstream changes
后续: Update ElementTree with upstream changes
stage: resolved
2010-02-16 13:13:41flox修改优先级: normal

抄送: + flox
消息: + msg99406

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