Minor: improve exception handling in exchange
This commit is contained in:
parent
18ec65e05f
commit
d4362ed357
@ -1041,9 +1041,9 @@ class Exchange:
|
|||||||
|
|
||||||
return matched_trades
|
return matched_trades
|
||||||
|
|
||||||
except ccxt.NetworkError as e:
|
except (ccxt.NetworkError, ccxt.ExchangeError) as e:
|
||||||
raise TemporaryError(
|
raise TemporaryError(
|
||||||
f'Could not get trades due to networking error. Message: {e}') from e
|
f'Could not get trades due to {e.__class__.__name__}. Message: {e}') from e
|
||||||
except ccxt.BaseError as e:
|
except ccxt.BaseError as e:
|
||||||
raise OperationalException(e) from e
|
raise OperationalException(e) from e
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user