From 18e32a2a0f616aa3caaac92850205f5538bd18ce Mon Sep 17 00:00:00 2001 From: erjemin Date: Thu, 9 Apr 2026 14:46:49 +0300 Subject: [PATCH] mod: upgrade django to 5.2 --- cadpoint/cadpoint/settings.py | 9 ++++----- poetry.lock | 12 ++++++------ pyproject.toml | 2 +- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/cadpoint/cadpoint/settings.py b/cadpoint/cadpoint/settings.py index 52fcc70..de8fb55 100644 --- a/cadpoint/cadpoint/settings.py +++ b/cadpoint/cadpoint/settings.py @@ -24,7 +24,7 @@ def _normalize_admin_url(value: str) -> str: # Quick-start development settings - unsuitable for production -# See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/ +# See https://docs.djangoproject.com/en/5.2/howto/deployment/checklist/ # SECURITY WARNING: keep the secret key used in production secret! SECRET_KEY = env('DJANGO_SECRET_KEY', default='django-insecure-change-me') @@ -99,7 +99,7 @@ TEMPLATES = [ WSGI_APPLICATION = 'cadpoint.wsgi.application' # Password validation -# https://docs.djangoproject.com/en/3.2/ref/settings/#auth-password-validators +# https://docs.djangoproject.com/en/5.2/ref/settings/#auth-password-validators AUTH_PASSWORD_VALIDATORS = [ {'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator', }, {'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', }, @@ -109,12 +109,11 @@ AUTH_PASSWORD_VALIDATORS = [ # Internationalization -# https://docs.djangoproject.com/en/3.2/topics/i18n/ +# https://docs.djangoproject.com/en/5.2/topics/i18n/ LANGUAGE_CODE = 'ru-RU' # <--------- RUSSIAN # TIME_ZONE = 'Etc/GMT+3' # TIME_ZONE = 'Europe/Moscow' # USE_I18N = True -USE_L10N = True USE_TZ = True # учитывать часовой пояс FIRST_DAY_OF_WEEK = 1 # неделя начинается с понедельника DEFAULT_CHARSET = 'utf-8' @@ -176,6 +175,6 @@ EMAIL_USE_TLS = True EMAIL_SUBJECT_PREFIX = '[CADPOINT.RU]: ' # префикс для оповещений об ошибках и необработанных исключениях # Default primary key field type -# https://docs.djangoproject.com/en/3.2/ref/settings/#default-auto-field +# https://docs.djangoproject.com/en/5.2/ref/settings/#default-auto-field DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField' diff --git a/poetry.lock b/poetry.lock index 27b2539..a51b9aa 100644 --- a/poetry.lock +++ b/poetry.lock @@ -173,17 +173,17 @@ test = ["pytest", "ruff"] [[package]] name = "django" -version = "4.2.30" +version = "5.2.13" description = "A high-level Python web framework that encourages rapid development and clean, pragmatic design." optional = false -python-versions = ">=3.8" +python-versions = ">=3.10" files = [ - {file = "django-4.2.30-py3-none-any.whl", hash = "sha256:4d07aaf1c62f9984842b67c2874ebbf7056a17be253860299b93ae1881faad65"}, - {file = "django-4.2.30.tar.gz", hash = "sha256:4ebc7a434e3819db6cf4b399fb5b3f536310a30e8486f08b66886840be84b37c"}, + {file = "django-5.2.13-py3-none-any.whl", hash = "sha256:5788fce61da23788a8ce6f02583765ab060d396720924789f97fa42119d37f7a"}, + {file = "django-5.2.13.tar.gz", hash = "sha256:a31589db5188d074c63f0945c3888fad104627dfcc236fb2b97f71f89da33bc4"}, ] [package.dependencies] -asgiref = ">=3.6.0,<4" +asgiref = ">=3.8.1" sqlparse = ">=0.3.1" tzdata = {version = "*", markers = "sys_platform == \"win32\""} @@ -743,4 +743,4 @@ files = [ [metadata] lock-version = "2.0" python-versions = ">=3.12,<3.13" -content-hash = "cf13db3bf3b15a2f88dfb865ab7a5a0507c76d1c8c1f0c66b63b17d27893cdf5" +content-hash = "c8a9496d279767e1ce179c985beb1f1813933c600163f061866c70fa413467d0" diff --git a/pyproject.toml b/pyproject.toml index 91bd8a0..4a6b1df 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ packages = [ [tool.poetry.dependencies] python = ">=3.12,<3.13" -Django = "^4.2" +Django = ">=5.2,<5.3" django-filer = "^3.4" easy-thumbnails = "^2.10" django-taggit = "^6.1"