tests: Run black in CI.

This commit is contained in:
tecnovert
2025-03-01 23:10:48 +02:00
parent 15b2038d65
commit 19968ed496
6 changed files with 23 additions and 21 deletions

View File

@@ -327,9 +327,7 @@ def formatBids(swap_client, bids, filters) -> bytes:
amount_to = None
if ci_to:
amount_to = ci_to.format_amount(
(b[4] * b[10]) // ci_from.COIN()
)
amount_to = ci_to.format_amount((b[4] * b[10]) // ci_from.COIN())
bid_data = {
"bid_id": b[2].hex(),
@@ -343,14 +341,13 @@ def formatBids(swap_client, bids, filters) -> bytes:
"bid_rate": swap_client.ci(b[14]).format_amount(b[10]),
"bid_state": strBidState(b[5]),
"addr_from": b[11],
"addr_to": offer.addr_to if offer else None
"addr_to": offer.addr_to if offer else None,
}
if with_extra_info:
bid_data.update({
"tx_state_a": strTxState(b[7]),
"tx_state_b": strTxState(b[8])
})
bid_data.update(
{"tx_state_a": strTxState(b[7]), "tx_state_b": strTxState(b[8])}
)
rv.append(bid_data)
return bytes(json.dumps(rv), "UTF-8")