Fix various flake8 errors

This commit is contained in:
Klaas van Schelven
2024-08-21 09:31:05 +02:00
parent 7ac78fe922
commit 129a8db421
11 changed files with 5 additions and 21 deletions

View File

@@ -1,3 +1 @@
from django.contrib import admin
# Register your models here.

View File

@@ -1,3 +1 @@
from django.db import models
# Create your models here.

View File

@@ -34,9 +34,9 @@ class Command(BaseCommand):
raise ValueError(msg)
def raise_exception_from(self, msg, e):
s = "foo"
l = ["bar", 1, None, ["bar", 1, None]]
d = {
s = "foo" # noqa unused variable, but we want to test that it shows up in the local variables in Bugsink
l = ["bar", 1, None, ["bar", 1, None]] # noqa
d = { # noqa
"foo": "bar",
"baz": 1,
"snu": None,

View File

@@ -1,3 +1 @@
from django.shortcuts import render
# Create your views here.

View File

@@ -1,3 +1 @@
from django.contrib import admin
# Register your models here.

View File

@@ -1,3 +1 @@
from django.test import TestCase
# Create your tests here.

View File

@@ -1,3 +1 @@
from django.shortcuts import render
# Create your views here.

View File

@@ -1,3 +1 @@
from django.test import TestCase
# Create your tests here.

View File

@@ -32,6 +32,6 @@ def short_given_now(value):
# because I want to compare 2 local times here (e.g. to know what the date boundary is)
# useful bits:
now = timezone.now()
now = timezone.now() # noqa
default_timezone = timezone.get_current_timezone()
timezone.localtime(value, default_timezone)

View File

@@ -1,6 +1,6 @@
[flake8]
max-line-length=120
exclude=venv,.venv,migrations
exclude=venv,.venv,**/migrations/*,sentry/**
extend-ignore=
# E741: ambiguous variable name
E741

View File

@@ -1,3 +1 @@
from django.test import TestCase
# Create your tests here.