From 01f91354d99b45d30d340c05eff81853f9692486 Mon Sep 17 00:00:00 2001 From: sunlei Date: Thu, 19 Dec 2024 17:16:02 +0800 Subject: [PATCH] Fix timeout error code for Bybit (#2130) --- nautilus_trader/adapters/bybit/websocket/client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nautilus_trader/adapters/bybit/websocket/client.py b/nautilus_trader/adapters/bybit/websocket/client.py index 2c662f2610c..c6508c5274c 100644 --- a/nautilus_trader/adapters/bybit/websocket/client.py +++ b/nautilus_trader/adapters/bybit/websocket/client.py @@ -452,7 +452,7 @@ async def _order( self._log.error(f"Order request `{req_id}` timed out. op={op}, args={args}") future.cancel() self._pending_order_requests.pop(req_id, None) - raise BybitError(code=-10_000, message="Request timed out") from e + raise BybitError(code=-10_408, message="Request timed out") from e return ack_resp