diff --git a/electrum/exchange_rate.py b/electrum/exchange_rate.py index 03b23356e..fe9d800e7 100644 --- a/electrum/exchange_rate.py +++ b/electrum/exchange_rate.py @@ -80,7 +80,7 @@ class ExchangeBase(Logger): self.logger.info(f"getting fx quotes for {ccy}") self.quotes = await self.get_rates(ccy) self.logger.info("received fx quotes") - except aiohttp.ClientError as e: + except (aiohttp.ClientError, asyncio.TimeoutError) as e: self.logger.info(f"failed fx quotes: {repr(e)}") self.quotes = {} except Exception as e: @@ -111,7 +111,7 @@ class ExchangeBase(Logger): self.logger.info(f"requesting fx history for {ccy}") h = await self.request_history(ccy) self.logger.info(f"received fx history for {ccy}") - except aiohttp.ClientError as e: + except (aiohttp.ClientError, asyncio.TimeoutError) as e: self.logger.info(f"failed fx history: {repr(e)}") return except Exception as e: