feat: добавить pyproject.toml
Объединены зависимости из requirements.txt и requirements-dev.txt, настройки pytest из pytest.ini, и базовая конфигурация ruff. Dockerfile обновлён: установка зависимостей через pyproject.toml. requirements.txt/pytest.ini сохранены для обратной совместимости.
This commit is contained in:
parent
089a77ce17
commit
81a99aaeab
@ -9,8 +9,8 @@ WORKDIR /app
|
|||||||
RUN mkdir -p logs
|
RUN mkdir -p logs
|
||||||
|
|
||||||
# Устанавливаем зависимости и утилиту ps для healthcheck
|
# Устанавливаем зависимости и утилиту ps для healthcheck
|
||||||
COPY requirements.txt .
|
COPY pyproject.toml .
|
||||||
RUN pip install --no-cache-dir -r requirements.txt && \
|
RUN pip install --no-cache-dir . && \
|
||||||
apt-get update && apt-get install -y --no-install-recommends tzdata procps && \
|
apt-get update && apt-get install -y --no-install-recommends tzdata procps && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
|||||||
25
pyproject.toml
Normal file
25
pyproject.toml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
[project]
|
||||||
|
name = "discord-bot"
|
||||||
|
version = "0.1.0"
|
||||||
|
description = "Discord бот с утренним дайджестом"
|
||||||
|
requires-python = ">=3.11"
|
||||||
|
dependencies = [
|
||||||
|
"discord.py~=2.7.1",
|
||||||
|
"python-dotenv~=1.2.2",
|
||||||
|
"requests~=2.34.2",
|
||||||
|
"defusedxml~=0.7.1",
|
||||||
|
]
|
||||||
|
|
||||||
|
[project.optional-dependencies]
|
||||||
|
dev = [
|
||||||
|
"pre-commit>=3.5.0",
|
||||||
|
"pytest>=7.4.0",
|
||||||
|
"pytest-asyncio>=0.21.0",
|
||||||
|
"ruff>=0.8.0",
|
||||||
|
]
|
||||||
|
|
||||||
|
[tool.pytest.ini_options]
|
||||||
|
asyncio_mode = "auto"
|
||||||
|
|
||||||
|
[tool.ruff]
|
||||||
|
target-version = "py311"
|
||||||
Loading…
x
Reference in New Issue
Block a user