diff --git a/httpcore/_async/http_proxy.py b/httpcore/_async/http_proxy.py index d24e88c2a..ee64d3132 100644 --- a/httpcore/_async/http_proxy.py +++ b/httpcore/_async/http_proxy.py @@ -101,6 +101,7 @@ def create_connection(self, origin: Origin) -> AsyncConnectionInterface: if origin.scheme == b"http": return AsyncForwardHTTPConnection( proxy_origin=self._proxy_url.origin, + proxy_headers=self._proxy_headers, keepalive_expiry=self._keepalive_expiry, network_backend=self._network_backend, ) diff --git a/httpcore/_sync/http_proxy.py b/httpcore/_sync/http_proxy.py index ac07273a4..d00b4d4f0 100644 --- a/httpcore/_sync/http_proxy.py +++ b/httpcore/_sync/http_proxy.py @@ -101,6 +101,7 @@ def create_connection(self, origin: Origin) -> ConnectionInterface: if origin.scheme == b"http": return ForwardHTTPConnection( proxy_origin=self._proxy_url.origin, + proxy_headers=self._proxy_headers, keepalive_expiry=self._keepalive_expiry, network_backend=self._network_backend, )