From: Bob Halley Date: Sun, 28 May 2023 20:58:27 +0000 (-0700) Subject: Httpx now has a socket_options parameter in its NetworkBackends. X-Git-Tag: v2.4.0rc1~16 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1cdd6f53922acdbc9d5aae573929e6681142c93a;p=thirdparty%2Fdnspython.git Httpx now has a socket_options parameter in its NetworkBackends. We accept this parameter if it is given, but do not actually do anything with it. In theory this shouldn't be a problem as we're never passing it either in the cases where we use our backends. --- diff --git a/dns/_asyncio_backend.py b/dns/_asyncio_backend.py index 4a26d7c1..0f163703 100644 --- a/dns/_asyncio_backend.py +++ b/dns/_asyncio_backend.py @@ -142,7 +142,7 @@ try: ) async def connect_tcp( - self, host, port, timeout, local_address + self, host, port, timeout, local_address, socket_options=None ): # pylint: disable=signature-differs addresses = [] _, expiration = _compute_times(timeout) @@ -175,7 +175,7 @@ try: raise httpcore.ConnectError async def connect_unix_socket( - self, path, timeout + self, path, timeout, socket_options=None ): # pylint: disable=signature-differs raise NotImplementedError diff --git a/dns/_trio_backend.py b/dns/_trio_backend.py index 76199230..ff5da9eb 100644 --- a/dns/_trio_backend.py +++ b/dns/_trio_backend.py @@ -112,7 +112,7 @@ try: self._family = family async def connect_tcp( - self, host, port, timeout, local_address + self, host, port, timeout, local_address, socket_options=None ): # pylint: disable=signature-differs addresses = [] _, expiration = _compute_times(timeout) @@ -148,7 +148,7 @@ try: raise httpcore.ConnectError async def connect_unix_socket( - self, path, timeout + self, path, timeout, socket_options=None ): # pylint: disable=signature-differs raise NotImplementedError diff --git a/dns/query.py b/dns/query.py index 1a1b566d..c6b05610 100644 --- a/dns/query.py +++ b/dns/query.py @@ -84,7 +84,7 @@ try: self._family = family def connect_tcp( - self, host, port, timeout, local_address + self, host, port, timeout, local_address, socket_options=None ): # pylint: disable=signature-differs addresses = [] _, expiration = _compute_times(timeout) @@ -123,7 +123,7 @@ try: raise httpcore.ConnectError def connect_unix_socket( - self, path, timeout + self, path, timeout, socket_options=None ): # pylint: disable=signature-differs raise NotImplementedError