Message207418
I just noticed through looking through someone else's WSGI framework that wsgiref is incorrectly handling URL handling. It does not go through the WSGI coding dance in the wsgiref.utils.request_uri function.
Testcase through werkzeug:
>>> from wsgiref.util import request_uri
>>> from werkzeug.test import create_environ
>>> from werkzeug.urls import url_parse, url_unquote
>>> env = create_environ('/\N{SNOWMAN}')
>>> url_parse(request_uri(env)).path
'/%C3%A2%C2%98%C2%83'
>>> url_unquote(url_parse(request_uri(env)).path)
'/â\x98\x83'
>>> _ == '/\N{SNOWMAN}'
False
If this passes tests then I'm assuming that wsgiref is doing the inverse bug somewhere else. I will look into it later, but this behavior is definitely broken. |
|
Date |
User |
Action |
Args |
2014-01-06 09:46:59 | aronacher | set | recipients:
+ aronacher |
2014-01-06 09:46:59 | aronacher | set | messageid: <1389001619.16.0.909145148031.issue20138@psf.upfronthosting.co.za> |
2014-01-06 09:46:59 | aronacher | link | issue20138 messages |
2014-01-06 09:46:58 | aronacher | create | |
|