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 2017年02月04日 20:29 by gboudreau, last changed 2022年04月11日 14:58 by admin. This issue is now closed.
| Messages (3) | |||
|---|---|---|---|
| msg286987 - (view) | Author: Guillaume Boudreau (gboudreau) | Date: 2017年02月04日 20:29 | |
Tested using urllib3 1.20
```
>>> import urllib3
>>> http = urllib3.PoolManager()
>>> r = http.request('GET', 'https://online.chasecanada.ca/ChaseCanada_Consumer/Login.do')
>>> r.status
200
>>> r.headers
HTTPHeaderDict({'Date': 'Sat, 04 Feb 2017 20:09:21 GMT'})
>>>
```
I'm pretty sure the problem is caused by an invalid HTTP header returned by the server:
HTTP/1.1 200 OK
Date: 2017年2月04日 19:16:34 GMT
My Param: None
[...]
It directly follows the Date response header, which is returned fine, but since no other response headers is returned, I think this broken header is breaking the HTTP response headers parser.
Of note: the `http.client.HTTPresponse.headers` object (`HTTPMessage`) shows all headers in `_payload`, but only the `Date` header in `_headers`.
Thus why I think this is a http.client issue, and not a urllib3 issue.
|
|||
| msg286990 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2017年02月04日 20:58 | |
This appears to be a duplicate of issue 24363. Does the patch there fix the problem for you? |
|||
| msg287023 - (view) | Author: Guillaume Boudreau (gboudreau) | Date: 2017年02月05日 00:10 | |
Yes, indeed. The latest patch in 24363 resolves this issue. Sorry for the duplicate. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:42 | admin | set | github: 73631 |
| 2017年02月05日 00:10:37 | gboudreau | set | messages: + msg287023 |
| 2017年02月04日 20:58:55 | r.david.murray | set | status: open -> closed superseder: httplib fails to handle semivalid HTTP headers nosy: + r.david.murray messages: + msg286990 resolution: duplicate stage: resolved |
| 2017年02月04日 20:29:53 | gboudreau | create | |