chore: run pyupgrade (#623)

- use `{...}` instead of `set([...])`
- do not use `class Foo(object):`, just use `class Foo:`
- do not specify default flags (`"r"`) for `open()`
This commit is contained in:
Pavol Rusnak
2024-09-24 13:53:35 +02:00
committed by GitHub
parent 870d75b205
commit 25f0763f94
16 changed files with 23 additions and 23 deletions

View File

@@ -10,7 +10,7 @@ from ..core.settings import settings
def amount_summary(proofs: List[Proof], unit: Unit) -> str:
amounts_we_have = [
(amount, len([p for p in proofs if p.amount == amount]))
for amount in set([p.amount for p in proofs])
for amount in {p.amount for p in proofs}
]
amounts_we_have.sort(key=lambda x: x[0])
return (