forked from bitcoinafterlife/bal-electrum-plugin
a lot
This commit is contained in:
@@ -23,9 +23,15 @@ class Willexecutors:
|
||||
def get_willexecutors(bal_plugin, update = False,bal_window=False,force=False,task=True):
|
||||
willexecutors = bal_plugin.WILLEXECUTORS.get()
|
||||
willexecutors=willexecutors.get(constants.net.NET_NAME,{})
|
||||
to_del=[]
|
||||
for w in willexecutors:
|
||||
if not isinstance(willexecutors[w],dict):
|
||||
to_del.append(w)
|
||||
continue
|
||||
Willexecutors.initialize_willexecutor(willexecutors[w],w)
|
||||
|
||||
for w in to_del:
|
||||
print("ERROR: WILLEXECUTOR TO DELETE:", w)
|
||||
del willexecutors[w]
|
||||
bal = bal_plugin.WILLEXECUTORS.default.get(constants.net.NET_NAME,{})
|
||||
for bal_url,bal_executor in bal.items():
|
||||
if not bal_url in willexecutors:
|
||||
@@ -172,6 +178,7 @@ class Willexecutors:
|
||||
if constants.net.NET_NAME!="mainnet":
|
||||
netname=constants.net.NET_NAME
|
||||
w = Willexecutors.send_request('get',url+"/"+netname+"/info")
|
||||
|
||||
willexecutor['url']=url
|
||||
willexecutor['status'] = w['status']
|
||||
willexecutor['base_fee'] = w['base_fee']
|
||||
@@ -204,7 +211,7 @@ class Willexecutors:
|
||||
return l
|
||||
|
||||
except Exception as e:
|
||||
_logger.error(f"error downloading willexecutors list:{e}")
|
||||
_logger.error(f"Failed to download willexecutors list: {e}")
|
||||
return {}
|
||||
def get_willexecutors_list_from_json(bal_plugin):
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user