1
0
Fork 0
mirror of https://github.com/EDeev/deev.space.git synced 2026-10-07 20:49:59 +03:00

Зависимости: закреплены версии, добавлены недостающие, убраны лишние

- добавлены python-dotenv (без него падал settings.py) и whitenoise;
- убраны неиспользуемые python-telegram-bot, vk-api, django-recaptcha, python-slugify;
- версии закреплены по рабочему окружению продакшена;
- requirements-dev.txt (pytest, pytest-django, ruff) и настройки ruff/pytest в pyproject.toml.
This commit is contained in:
Деев Егор Викторович 2026-10-02 11:59:07 +00:00
parent 878b4580e4
commit 312ce5a24a
3 changed files with 33 additions and 11 deletions

20
pyproject.toml Normal file
View file

@ -0,0 +1,20 @@
[tool.ruff]
target-version = "py310"
line-length = 120
extend-exclude = ["main/migrations"]
[tool.ruff.lint]
select = ["E", "F", "W", "B", "S", "UP", "I"]
ignore = [
"E501", # длинные строки — в шаблонах сообщений и help_text
"S308", # mark_safe — проверяется вручную
"UP031", # %-форматирование в логах — осознанно
]
[tool.ruff.lint.per-file-ignores]
"main/tests/*" = ["S101", "S106"]
"main/management/commands/*" = ["S311"]
[tool.pytest.ini_options]
DJANGO_SETTINGS_MODULE = "dspace.settings"
python_files = ["test_*.py"]

4
requirements-dev.txt Normal file
View file

@ -0,0 +1,4 @@
-r requirements.txt
pytest==8.4.2
pytest-django==4.11.1
ruff==0.14.0

View file

@ -1,11 +1,9 @@
Django>=4.2,<5.0 Django==4.2.27
Pillow>=10.0.0 python-dotenv==1.2.1
python-slugify>=8.0.0 Pillow==12.0.0
Unidecode>=1.3.0 bleach==6.3.0
bleach>=6.0.0 beautifulsoup4==4.14.3
requests>=2.31.0 requests==2.32.5
python-telegram-bot>=20.0 Unidecode==1.4.0
vk-api>=11.9.9 whitenoise==6.11.0
django-recaptcha>=3.0.0 gunicorn==23.0.0
gunicorn>=21.0.0
beautifulsoup4>=4.12.0