bug: fix a missed check for missing pool info.
This commit is contained in:
@@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
import ipaddress
|
import ipaddress
|
||||||
import logging
|
import logging
|
||||||
|
import warnings
|
||||||
from collections import namedtuple
|
from collections import namedtuple
|
||||||
from typing import List, Optional, Tuple, Union
|
from typing import List, Optional, Tuple, Union
|
||||||
|
|
||||||
@@ -151,6 +152,12 @@ class BTMiner(BaseMiner):
|
|||||||
summary = data["summary"][0]
|
summary = data["summary"][0]
|
||||||
except APIError as e:
|
except APIError as e:
|
||||||
logging.warning(e)
|
logging.warning(e)
|
||||||
|
except LookupError:
|
||||||
|
# somethings wrong with the miner
|
||||||
|
warnings.warn(
|
||||||
|
f"Failed to gather pool config for miner: {self}, miner did not return pool information."
|
||||||
|
)
|
||||||
|
pass
|
||||||
|
|
||||||
if pools:
|
if pools:
|
||||||
if "POOLS" in pools:
|
if "POOLS" in pools:
|
||||||
|
|||||||
Reference in New Issue
Block a user