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 taleinat
Recipients Jonathan.Gossage, amaury.forgeotdarc, christian.heimes, cms103, loewis, taleinat
Date 2018-10-14.09:13:11
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1539508392.14.0.788709270274.issue6686@psf.upfronthosting.co.za>
In-reply-to
Content
See additional research and discussion in the comments of PR GH-9715.

Simply changing this to return a string rather than bytes would break backwards compatibility.

I certainly agree that this should have returned a string in the first place, especially since the Unicode decoding is otherwise completely abstracted away and the encoding used is not made available.

Our options:

1. Return a string starting with 3.8, document the change in What's New & fix the docs for older 3.x.
2. Continue returning bytes, update the docs for all 3.x that this returns bytes, and that there's no good way to know the proper encoding to use for decoding it.
3. As 2 above, but also expose the encoding used.

Since this appears to be rarely used and option 3 requires significantly more effort than the others, I am against it. 

Option 2 seems the safest, but I'd like to hear more from those more experienced with XML.
History
Date User Action Args
2018-10-14 09:13:12taleinatsetrecipients: + taleinat, loewis, amaury.forgeotdarc, christian.heimes, cms103, Jonathan.Gossage
2018-10-14 09:13:12taleinatsetmessageid: <1539508392.14.0.788709270274.issue6686@psf.upfronthosting.co.za>
2018-10-14 09:13:12taleinatlinkissue6686 messages
2018-10-14 09:13:11taleinatcreate