Display proxy protocol scheme on error (#3571)

This commit is contained in:
Emmanuel Ferdman 2025-06-02 22:29:52 +03:00 committed by GitHub
parent 6c7af96773
commit 336204f012
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -355,7 +355,7 @@ class AsyncHTTPTransport(AsyncBaseTransport):
else: # pragma: no cover
raise ValueError(
"Proxy protocol must be either 'http', 'https', 'socks5', or 'socks5h',"
" but got {proxy.url.scheme!r}."
f" but got {proxy.url.scheme!r}."
)
async def __aenter__(self: A) -> A: # Use generics for subclass support.