diff --git a/backend/accounts/migrations/0004_user_profile_pic.py b/backend/accounts/migrations/0004_user_profile_pic.py index 3a203f7a..2f10da8c 100644 --- a/backend/accounts/migrations/0004_user_profile_pic.py +++ b/backend/accounts/migrations/0004_user_profile_pic.py @@ -1,8 +1,9 @@ # Generated by Django 4.1.3 on 2022-11-10 02:05 -import accounts.models from django.db import migrations, models +import accounts.models + class Migration(migrations.Migration): dependencies = [ diff --git a/backend/accounts/migrations/0005_privacyresource_privacysetting.py b/backend/accounts/migrations/0005_privacyresource_privacysetting.py index b5ce7e07..c085bf58 100644 --- a/backend/accounts/migrations/0005_privacyresource_privacysetting.py +++ b/backend/accounts/migrations/0005_privacyresource_privacysetting.py @@ -1,8 +1,8 @@ # Generated by Django 3.2.9 on 2023-03-04 21:59 +import django.db.models.deletion from django.conf import settings from django.db import migrations, models -import django.db.models.deletion class Migration(migrations.Migration): diff --git a/backend/identity/urls.py b/backend/identity/urls.py index 3a1a7424..8becdf4c 100644 --- a/backend/identity/urls.py +++ b/backend/identity/urls.py @@ -1,4 +1,5 @@ from django.urls import path + from identity.views import AttestView, JwksInfoView, RefreshJWTView diff --git a/backend/identity/views.py b/backend/identity/views.py index 5265c318..5e2cf08c 100644 --- a/backend/identity/views.py +++ b/backend/identity/views.py @@ -6,15 +6,16 @@ from django.utils.text import slugify from django.views.decorators.csrf import csrf_exempt from django.views.generic import View +from jwcrypto import jwt +from oauth2_provider.settings import oauth2_settings +from oauth2_provider.views.mixins import OAuthLibMixin + from identity.utils import ( ID_PRIVATE_KEY, SIGNING_ALG, mint_access_jwt, mint_refresh_jwt, ) -from jwcrypto import jwt -from oauth2_provider.settings import oauth2_settings -from oauth2_provider.views.mixins import OAuthLibMixin @method_decorator(csrf_exempt, name="dispatch") diff --git a/backend/tests/identity/test_views.py b/backend/tests/identity/test_views.py index b2129ce2..08f1c9c3 100644 --- a/backend/tests/identity/test_views.py +++ b/backend/tests/identity/test_views.py @@ -1,4 +1,3 @@ -import base64 import json import time from http import HTTPStatus @@ -7,10 +6,11 @@ from django.contrib.auth import get_user_model from django.test import Client, TestCase from django.urls import reverse -from identity.views import SIGNING_ALG from jwcrypto import jwk, jwt from oauth2_provider.models import get_application_model +from identity.views import SIGNING_ALG + class AttestTestCase(TestCase): def setUp(self):