mirror of
https://github.com/basicswap/basicswap.git
synced 2025-11-06 02:38:11 +01:00
Fail with more descriptive error when processing message involving inactive coin.
This commit is contained in:
@@ -25,6 +25,13 @@ class AutomationConstraint(ValueError):
|
||||
pass
|
||||
|
||||
|
||||
class InactiveCoin(Exception):
|
||||
def __init__(self, coinid):
|
||||
self.coinid = coinid
|
||||
def __str__(self):
|
||||
return str(self.coinid)
|
||||
|
||||
|
||||
def ensure(v, err_string):
|
||||
if not v:
|
||||
raise ValueError(err_string)
|
||||
|
||||
Reference in New Issue
Block a user