reorganize imports with ruff

This commit is contained in:
thomas girod
2024-06-24 13:07:36 +02:00
parent 9bdf3fc4ac
commit 3143d3d91a
170 changed files with 702 additions and 804 deletions

View File

@ -24,12 +24,9 @@
from django import forms
from django.utils.translation import gettext_lazy as _
from django.forms.widgets import Widget
from django.templatetags.static import static
from core.views.forms import MarkdownInput
from core.models import User
from core.views.forms import MarkdownInput
from pedagogy.models import UV, UVComment, UVCommentReport

View File

@ -2,10 +2,10 @@
# Generated by Django 1.11.20 on 2019-07-05 14:32
from __future__ import unicode_literals
from django.conf import settings
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion
from django.conf import settings
from django.db import migrations, models
class Migration(migrations.Migration):

View File

@ -22,14 +22,13 @@
#
#
from django.db import models
from django.utils.translation import gettext_lazy as _
from django.utils import timezone
from django.core import validators
from django.conf import settings
from django.utils.functional import cached_property
from django.core import validators
from django.db import models
from django.urls import reverse
from django.utils import timezone
from django.utils.functional import cached_property
from django.utils.translation import gettext_lazy as _
from rest_framework import serializers
from core.models import User

View File

@ -23,7 +23,6 @@
#
from django.db import models
from haystack import indexes, signals
from core.search_indexes import BigCharFieldIndex

View File

@ -23,13 +23,12 @@
#
from django.conf import settings
from django.core.management import call_command
from django.test import TestCase
from django.urls import reverse
from django.utils.translation import gettext_lazy as _
from django.core.management import call_command
from core.models import User, Notification
from core.models import Notification, User
from pedagogy.models import UV, UVComment, UVCommentReport

View File

@ -22,38 +22,35 @@
#
#
from django.conf import settings
from django.core.exceptions import ObjectDoesNotExist, PermissionDenied
from django.http import HttpResponse
from django.shortcuts import get_object_or_404
from django.urls import reverse, reverse_lazy
from django.utils import html
from django.views.generic import (
CreateView,
DeleteView,
UpdateView,
ListView,
FormView,
ListView,
UpdateView,
View,
)
from django.utils import html
from django.http import HttpResponse
from django.core.exceptions import PermissionDenied, ObjectDoesNotExist
from django.urls import reverse_lazy, reverse
from django.shortcuts import get_object_or_404
from django.conf import settings
from haystack.query import SearchQuerySet
from rest_framework.renderers import JSONRenderer
from core.models import Notification, RealGroup
from core.views import (
DetailFormView,
CanCreateMixin,
CanEditMixin,
CanViewMixin,
CanEditPropMixin,
CanViewMixin,
DetailFormView,
)
from core.models import RealGroup, Notification
from pedagogy.forms import (
UVForm,
UVCommentForm,
UVCommentReportForm,
UVCommentModerationForm,
UVCommentReportForm,
UVForm,
)
from pedagogy.models import UV, UVComment, UVCommentReport, UVSerializer