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.
Created on 2016年08月15日 07:20 by ncoghlan, last changed 2022年04月11日 14:58 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg272725 - (view) | Author: Alyssa Coghlan (ncoghlan) * (Python committer) | Date: 2016年08月15日 07:20 | |
In two recent Python 3 porting projects, a key incompatibility I encountered was that "json.loads(data)" on UTF-8 encoded bytes required an explicit decoding step under Python 3, rather than implicitly decoding the data as UTF-8. Unlike many other wire formats, assuming UTF-8 for binary JSON data is a pretty safe assumption, and there's no type ambiguity here since the output type is still a properly decoded JSON object. (This RFE has been split out from the larger RFE at #19837, which also covers implicit *encoding* to UTF-8, which is a more questionable idea) |
|||
| msg272728 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2016年08月15日 07:29 | |
This looks as a duplicate of issue10976. See also issue17909 (which covers not just UTF-8, but UTF-16 and UTF-32, in conforming with RFC 4627). |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:34 | admin | set | github: 71952 |
| 2016年08月17日 12:36:03 | berker.peksag | set | stage: needs patch -> resolved |
| 2016年08月17日 12:20:36 | vstinner | set | status: open -> closed superseder: accept bytes in json.loads() resolution: duplicate |
| 2016年08月15日 07:29:13 | serhiy.storchaka | set | nosy:
+ serhiy.storchaka messages: + msg272728 |
| 2016年08月15日 07:20:28 | ncoghlan | create | |