[issue42893] Strange XPath search behavior of xml.etree.ElementTree.Element.find
robpats
report at bugs.python.org
Thu Jan 14 20:53:49 EST 2021
robpats <robotpats at gmail.com> added the comment:
Thanks for the pointer. I didn't notice this paragraph.
xml.etree.ElementTree.Element.find currently returns None if XPath expression is invalid or unsupported. I think it should also return None if position predicates are not preceded by a tag name. It would be even better to emit warnings or raise exceptions to indicate any errors.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue42893>
_______________________________________
More information about the Python-bugs-list
mailing list