mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Problem: Need better exception handling for store_unspent_outputs
Solution: Added an error message in case of a `DuplicateKeyError`
This commit is contained in:
parent
96932793b1
commit
b8d55e928d
@ -228,7 +228,9 @@ def store_unspent_outputs(conn, *unspent_outputs):
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
except DuplicateKeyError:
|
except DuplicateKeyError:
|
||||||
# TODO log warning at least
|
raise DuplicateKeyError(
|
||||||
|
f'Duplicate keys in transactions [{unspent_outputs}].'
|
||||||
|
)
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user