Serhiy Storchaka <storchaka+cpyt...@gmail.com> added the comment:

xml.etree.cElementTree should be treated in the same way as cStringIO and 
cPickle -- they where separate modules in the past, but now the acceleration is 
used by default in io.StringIO and pickle. It looks an oversign that it was not 
removed in 3.0.

xml.etree.cElementTree was deprecated since 3.3. I think 6 releases (3.3-3.8) 
is long enough period. It was not possible to emit a deprecation warning at 
runtime for reasons mentioned above. And we did not have deprecation warnings 
for cStringIO and cPickle for the same reasons.

defusedxml is the only known to me package which does not fall back to 
xml.etree.ElementTree. I hope it is easy to fix it. In Python 
xml.etree.cElementTree is the same as xml.etree.ElementTree, so you can just 
import xml.etree.ElementTree. And you can use the above mentioned idiom if you 
still support Python 2.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue36543>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to