Skip to content

Commit 842d01c

Browse files
authored
fix: SaslServer busy-loop causes process hang after test suite (#3305)
1 parent 9f20f32 commit 842d01c

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

tests/catalog/test_hive.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,21 +226,24 @@ def run(self) -> None:
226226
client.write(self._response)
227227
client.flush()
228228
except Exception:
229-
pass
229+
break
230230

231231
@property
232232
def port(self) -> int | None:
233233
self._port_bound.wait()
234234
return self._port
235235

236236
def close(self) -> None:
237-
# Close all client connections first
237+
try:
238+
self._socket.close()
239+
except Exception:
240+
pass
241+
self.join(timeout=5)
238242
for client in self._clients:
239243
try:
240244
client.close()
241245
except Exception:
242246
pass
243-
self._socket.close()
244247

245248

246249
@pytest.fixture(scope="session")

0 commit comments

Comments
 (0)