italia/spid-cie-oidc-django

View on GitHub
examples/wallet_trust_anchor/wallet_trust_anchor/settings.py

Summary

Maintainability
C
1 day
Test Coverage
Similar blocks of code found in 2 locations. Consider refactoring.
"""
Similar blocks of code found in 2 locations. Consider refactoring.
Django settings for example project.
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
Generated by 'django-admin startproject' using Django 4.0.2.
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
For more information on this file, see
Similar blocks of code found in 2 locations. Consider refactoring.
https://docs.djangoproject.com/en/4.0/topics/settings/
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
For the full list of settings and their values, see
Similar blocks of code found in 2 locations. Consider refactoring.
https://docs.djangoproject.com/en/4.0/ref/settings/
Similar blocks of code found in 2 locations. Consider refactoring.
"""
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
from pathlib import Path
Similar blocks of code found in 2 locations. Consider refactoring.
from .settingslocal import * # noqa: F401
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
# Build paths inside the project like this: BASE_DIR / 'subdir'.
Similar blocks of code found in 2 locations. Consider refactoring.
BASE_DIR = Path(__file__).resolve().parent.parent
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
# Quick-start development settings - unsuitable for production
Similar blocks of code found in 2 locations. Consider refactoring.
# See https://docs.djangoproject.com/en/4.0/howto/deployment/checklist/
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
MIDDLEWARE = [
Similar blocks of code found in 2 locations. Consider refactoring.
'django.middleware.security.SecurityMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.contrib.sessions.middleware.SessionMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.middleware.common.CommonMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.middleware.csrf.CsrfViewMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.contrib.auth.middleware.AuthenticationMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.contrib.messages.middleware.MessageMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.middleware.clickjacking.XFrameOptionsMiddleware',
Similar blocks of code found in 2 locations. Consider refactoring.
]
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
ROOT_URLCONF = 'wallet_trust_anchor.urls'
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
TEMPLATES = [
Similar blocks of code found in 2 locations. Consider refactoring.
{
Similar blocks of code found in 2 locations. Consider refactoring.
'BACKEND': 'django.template.backends.django.DjangoTemplates',
Similar blocks of code found in 2 locations. Consider refactoring.
'DIRS': ['templates'],
Similar blocks of code found in 2 locations. Consider refactoring.
'APP_DIRS': True,
Similar blocks of code found in 2 locations. Consider refactoring.
'OPTIONS': {
Similar blocks of code found in 2 locations. Consider refactoring.
'context_processors': [
Similar blocks of code found in 2 locations. Consider refactoring.
'django.template.context_processors.debug',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.template.context_processors.request',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.contrib.auth.context_processors.auth',
Similar blocks of code found in 2 locations. Consider refactoring.
'django.contrib.messages.context_processors.messages',
Similar blocks of code found in 2 locations. Consider refactoring.
],
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
]
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
WSGI_APPLICATION = 'wallet_trust_anchor.wsgi.application'
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
# Password validation
Similar blocks of code found in 2 locations. Consider refactoring.
# https://docs.djangoproject.com/en/4.0/ref/settings/#auth-password-validators
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
AUTH_PASSWORD_VALIDATORS = [
Similar blocks of code found in 2 locations. Consider refactoring.
{
Similar blocks of code found in 2 locations. Consider refactoring.
'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator',
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
{
Similar blocks of code found in 2 locations. Consider refactoring.
'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator',
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
{
Similar blocks of code found in 2 locations. Consider refactoring.
'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator',
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
{
Similar blocks of code found in 2 locations. Consider refactoring.
'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator',
Similar blocks of code found in 2 locations. Consider refactoring.
},
Similar blocks of code found in 2 locations. Consider refactoring.
]
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
# Static files (CSS, JavaScript, Images)
Similar blocks of code found in 2 locations. Consider refactoring.
# https://docs.djangoproject.com/en/4.0/howto/static-files/
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
STATIC_URL = 'static/'
Similar blocks of code found in 2 locations. Consider refactoring.
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
# Default primary key field type
Similar blocks of code found in 2 locations. Consider refactoring.
# https://docs.djangoproject.com/en/4.0/ref/settings/#default-auto-field
Similar blocks of code found in 2 locations. Consider refactoring.
 
Similar blocks of code found in 2 locations. Consider refactoring.
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'