Avoid unnecessary data collection conversion by making use of urllib3's HTTPHeaderDict for request headers
See original GitHub issueAvoid unnecessary data collection conversion by making use of urllib3’s HTTPHeaderDict
for request headers & response headers. Currently request http headers are placed in a CaseInsensitiveDict
but before a request is made the headers are converted to urllib3’s HTTPHeaderDict
& similar seems to occur for responses (in reverse).
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Get a header with Python and convert in JSON (requests - urllib2
If you are only interested in the header, make a head request. convert the CaseInsensitiveDict in a dict object and then convert it...
Read more >Requests Documentation - Read the Docs
Most unicode charsets are seamlessly decoded. When you make a request, Requests makes educated guesses about the encoding of the response based ...
Read more >urllib3 Documentation
You can use request() to make requests using any HTTP verb: > ... The HTTPResponse object provides status, data, and header attributes:.
Read more >Prevent unnecessary network requests with the HTTP Cache
All HTTP requests that the browser makes are first routed to the browser cache to check whether there is a valid cached response...
Read more >How to send HTTP headers using Python Requests Library?
The Requests Library is based on the urllib3 library and hides the complexity of making HTTP requests behind a simple API. Although the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
HTTP Handshake requires some information exchange, made by headers…
It probably is, but will it be faster if we have to layer tonnes of extra logic on top of things to support backwards compatibility? Also our current CaseInsensitiveDict’s interactions with the outside world probably aren’t well tested enough to have any confidence in that migration