mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-12 21:22:36 +01:00
Fediverse and Poll: Run Black
This commit is contained in:
parent
feaa02ab6d
commit
8326d6ef7f
@ -100,7 +100,7 @@ class NetworkedFediverseTestCase(BaseFediverseTestCase):
|
||||
|
||||
|
||||
class NetworklessFediverseTestCase(BaseFediverseTestCase):
|
||||
timeout = 1.
|
||||
timeout = 1.0
|
||||
|
||||
@contextlib.contextmanager
|
||||
def mockWebfingerSupport(self, value):
|
||||
|
@ -133,14 +133,17 @@ class Poll_(callbacks.Plugin):
|
||||
|
||||
answers = [(answer.split()[0], answer) for answer in answers]
|
||||
|
||||
answer_id_counts = collections.Counter(id_ for (id_, _) in answers).items()
|
||||
answer_id_counts = collections.Counter(
|
||||
id_ for (id_, _) in answers
|
||||
).items()
|
||||
duplicate_answer_ids = [
|
||||
answer_id for (answer_id, count) in answer_id_counts if count > 1
|
||||
]
|
||||
if duplicate_answer_ids:
|
||||
irc.error(
|
||||
format(
|
||||
_("Duplicate answer identifier(s): %L"), duplicate_answer_ids
|
||||
_("Duplicate answer identifier(s): %L"),
|
||||
duplicate_answer_ids,
|
||||
),
|
||||
Raise=True,
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user