ib.api: return None on manual quote timeout
parent
e54c3dc523
commit
778d26067d
|
@ -786,7 +786,7 @@ class Client:
|
|||
timeout: float = 1,
|
||||
raise_on_timeout: bool = False,
|
||||
|
||||
) -> Ticker:
|
||||
) -> Ticker | None:
|
||||
'''
|
||||
Return a single (snap) quote for symbol.
|
||||
|
||||
|
@ -811,7 +811,7 @@ class Client:
|
|||
except TimeoutError:
|
||||
if raise_on_timeout:
|
||||
raise
|
||||
return tkr
|
||||
return None
|
||||
|
||||
if tkr:
|
||||
break
|
||||
|
|
Loading…
Reference in New Issue