-
-
Couldn't load subscription status.
- Fork 2.1k
Open
Labels
Description
Is your feature request related to a problem?
Lines 502 to 507 in e79b2d5
| if proxy is None: | |
| proxy = self._default_proxy | |
| if proxy_auth is None: | |
| proxy_auth = self._default_proxy_auth | |
Lines 609 to 617 in e79b2d5
| if proxy is not None: | |
| proxy = URL(proxy) | |
| elif self._trust_env: | |
| with suppress(LookupError): | |
| proxy, proxy_auth = get_env_proxy_for_url(url) | |
| req = self._request_class( | |
| method, |
currently, the async def _request(...)
- uses proxy from env first than from code
- it at the same time causes calling
get env proxyfromenv and registryin each request(aka _request()) call.
Describe the solution you'd like
keep env proxy in session, and use after code proxy that provided by users
also should throw error for socks5 proxy since aiohttp does not work with socks5 currently
Describe alternatives you've considered
N/A
Related component
Client
Additional context
No response
Code of Conduct
- I agree to follow the aio-libs Code of Conduct