[core] Enable ruff B (flake8-bugbear) lint family (#16655)

This commit is contained in:
J. Nick Koston
2026-05-25 21:28:14 -05:00
committed by GitHub
parent 489cf483d0
commit ae814cff5c
27 changed files with 54 additions and 50 deletions

View File

@@ -407,8 +407,10 @@ async def wait_and_connect_api_client(
# Wait for connection with timeout
try:
await asyncio.wait_for(connected_future, timeout=timeout)
except TimeoutError:
raise TimeoutError(f"Failed to connect to API after {timeout} seconds")
except TimeoutError as err:
raise TimeoutError(
f"Failed to connect to API after {timeout} seconds"
) from err
if return_disconnect_event:
yield client, disconnect_event