Message177450
The requirement per PEP 3333 is that the original byte string needs to be converted to native string (Unicode) with the ISO-8891-1 encoding. This is to ensure that the original bytes are preserved so that the WSGI application, with its own knowledge of what encoding the byte string was in, can then properly convert it to the correct encoding.
In other words, the WSGI server is not allowed to assume that the original byte string was UTF-8, because in practice it may not be and it cannot know what it is. The WSGI server must use ISO-8859-1. The WSGI application if it needs it in UTF-8, must then convert it back to a byte string using IS0-8859-1 and then from there convert it back to a native string as UTF-8.
So if I understand what you are saying, you are suggesting a change which is incompatible with PEP 3333.
Please provide a code snippet or patch to show what you are proposing to be changed so it can be determined precisely what you are talking about. |
|
Date |
User |
Action |
Args |
2012-12-14 08:42:39 | grahamd | set | recipients:
+ grahamd, claudep |
2012-12-14 08:42:39 | grahamd | set | messageid: <1355474559.23.0.860505610303.issue16679@psf.upfronthosting.co.za> |
2012-12-14 08:42:39 | grahamd | link | issue16679 messages |
2012-12-14 08:42:38 | grahamd | create | |
|