From 15670f0ab1af34e4c31e4b601e158610ab13dbea Mon Sep 17 00:00:00 2001 From: Markus Hilger Date: Mon, 27 Jul 2026 01:54:01 +0200 Subject: [PATCH] Put the local socket in non-blocking mode in the async client _connect_unix left the socket blocking, while _connect_tls sets a zero timeout, so every loop.sock_recv and sock_sendall against the local socket ran the blocking call inline and stalled the whole event loop. nodeconsole --video showed this most clearly: a power action opens its own session, so the tiles stopped refreshing and keystrokes went unhandled until the BMC finished. asyncio only enforces this in debug mode, where the client failed outright with ValueError: the socket must be non-blocking. The descriptor passing retries in asynctlvdata also assume a non-blocking socket, since they wait for BlockingIOError. --- confluent_client/confluent/asynclient.py | 1 + 1 file changed, 1 insertion(+) diff --git a/confluent_client/confluent/asynclient.py b/confluent_client/confluent/asynclient.py index 1064a2aa..2f29e2e6 100644 --- a/confluent_client/confluent/asynclient.py +++ b/confluent_client/confluent/asynclient.py @@ -396,6 +396,7 @@ class Command(object): self.connection = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) self.connection.setsockopt(socket.SOL_SOCKET, SO_PASSCRED, 1) self.connection.connect(self.serverloc) + self.connection.setblocking(False) async def _connect_tls(self): server, port = _parseserver(self.serverloc)