Fix handling of http (vs https) proxy creation
The requests library requires both 'http' and 'https' values in any included proxy dict, and whoogle was previously copying the http proxy to https for simplicity. The assumption was that if the underlying request wasn't able to connect via https, it would default to http (otherwise why have the requirement to specify both?) This led to connectivity issues for users with http only proxies as of the latest urllib and requests package versions, which are a lot more strict with connections over https. With the latest versions, if an https connection cannot be made, the library returns an error. As a result, the new proxy dict must look something like this for plain http proxies: {'http': 'http://domain.tld:port', 'https': 'http://domain.tld:port'} where both http and https are identical, but both are still required.pull/355/head
parent
a64a86efb6
commit
e7a604d428
Loading…
Reference in New Issue