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.

Author rhettinger
Recipients Marco Sulla, eli.bendersky, rhettinger, scoder, serhiy.storchaka
Date 2019-08-21.22:12:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1566425540.89.0.362269439473.issue37792@roundup.psfhosted.org>
In-reply-to
Content
Macro, we appreciate your sentiments.  Please consider this module has been around for a long time and that others aren't reacting to the API the same way you are.  Deprecating SubElement, fromstringlist() and tostringlist() because you don't like them will just cause disruption to existing, deployed code.  You're about 15 years too late for a design discussion ;-)  That ship has sailed. 

Your proposal to add a new feature for comparing elements is in the realm of the possible.  That said, the other respondents made a reasonable case the different people would want to do it differently.  Despite your insistence that only your way makes sense, we do have to consider other users as well.  The other respondents provided you with other ways to meet your needs. Their disinclination to not add this feature is backed-up by years of experience with this module and with lxml.

Communication note: Please do not go down of the path of making yourself the arbiter of what is Pythonic or standard.  The other core devs in this conversation are highly experienced.  Insulting them or the Fredrik Lundh's existing API won't help matters.

We should add a clear note to the docs:  "Comparing the string serialized XML should not be used to establish semantic equality.  The preferred ways are to use C14N canonicalization or to write a tree walker where the notion of equivalence can be customized to include/exclude attribute order, to include/exclude comments or processing instructions, to include/exclude whitespace at non-leaf nodes".
History
Date User Action Args
2019-08-21 22:12:20rhettingersetrecipients: + rhettinger, scoder, eli.bendersky, serhiy.storchaka, Marco Sulla
2019-08-21 22:12:20rhettingersetmessageid: <1566425540.89.0.362269439473.issue37792@roundup.psfhosted.org>
2019-08-21 22:12:20rhettingerlinkissue37792 messages
2019-08-21 22:12:20rhettingercreate