Merge pull request #5368 from jsangmeister/fix-flake
Fixed formatting after flake update
This commit is contained in:
commit
b7b27d2e88
@ -822,7 +822,7 @@ class UserLoginView(WhoAmIDataView):
|
||||
user = User.objects.get(username="admin")
|
||||
if user.check_password("admin"):
|
||||
context["login_info_text"] = (
|
||||
f"Use <strong>admin</strong> and <strong>admin</strong> for your first login.<br>"
|
||||
"Use <strong>admin</strong> and <strong>admin</strong> for your first login.<br>"
|
||||
"Please change your password to hide this message!"
|
||||
)
|
||||
except User.DoesNotExist:
|
||||
|
@ -52,7 +52,7 @@ class WebsocketLatencyLogger:
|
||||
""" Calc Stats and print to logger. """
|
||||
N = len(self.latencies)
|
||||
mean = sum(self.latencies) / N
|
||||
std = sum((l - mean) ** 2 for l in self.latencies)
|
||||
std = sum((latency - mean) ** 2 for latency in self.latencies)
|
||||
self.logger.debug(f"N={N}, mean={mean:.2f}, std={std:.2f}")
|
||||
|
||||
self.reset()
|
||||
|
@ -86,8 +86,7 @@ class Command(BaseCommand):
|
||||
parser.add_argument(
|
||||
"--only",
|
||||
action="store_true",
|
||||
help="Only the given objects are created i. e. all defaults are "
|
||||
"set to 0.",
|
||||
help="Only the given objects are created i. e. all defaults are set to 0.",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-t",
|
||||
@ -112,9 +111,13 @@ class Command(BaseCommand):
|
||||
"--users",
|
||||
nargs=2,
|
||||
type=int,
|
||||
help=f"Number of users to be created. The first number of users is "
|
||||
'added to the group "Staff" (default {DEFAULT_NUMBER}). The second number '
|
||||
"of users is not added to any group (default {DEFAULT_NUMBER}).",
|
||||
help=dedent(
|
||||
f"""
|
||||
Number of users to be created. The first number of users is added \
|
||||
to the group "Staff" (default {DEFAULT_NUMBER}). The second number \
|
||||
of users is not added to any group (default {DEFAULT_NUMBER}).
|
||||
"""
|
||||
),
|
||||
)
|
||||
|
||||
def handle(self, *args, **options):
|
||||
|
@ -66,7 +66,7 @@ def test_list_of_speakers_db_queries():
|
||||
Motion.objects.create(title="motion2")
|
||||
Assignment.objects.create(title="assignment", open_posts=5)
|
||||
Mediafile.objects.create(
|
||||
title=f"mediafile", mediafile=SimpleUploadedFile(f"some_file", b"some content.")
|
||||
title="mediafile", mediafile=SimpleUploadedFile("some_file", b"some content.")
|
||||
)
|
||||
|
||||
assert count_queries(ListOfSpeakers.get_elements)() == 6
|
||||
|
Loading…
Reference in New Issue
Block a user