-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
141 lines (122 loc) · 3.27 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
[tool.ruff]
target-version = 'py311'
line-length = 100
exclude = [
'.git',
'.venv',
'.mypy_cache',
'.pytest_cache',
'.github',
]
lint.select = ['ALL']
lint.ignore = [
'ANN101', # missing-type-self
'EM', # flake8-errmsg
'D100', 'D101', 'D102', 'D103', 'D104', 'D105', 'D106', 'D107', 'D203', 'D212', # pydocstyle
'TRY003', # Avoid specifying long messages outside the exception class
'TD002', 'TD003', # Missing author/issue link for TODO
'FIX', # flake8-fixme
'PD901', # `df` is a bad variable name. Be kinder to your future self.
]
[tool.ruff.lint.flake8-quotes]
inline-quotes = 'single'
[tool.ruff.lint.isort]
lines-after-imports = 2
known-first-party = ['app']
[tool.ruff.lint.extend-per-file-ignores]
'tests/*' = [
'ANN', # flake8-annotations\
'ARG001', # Unused function argument: %s
'PT001', # Use @pytest.fixture{expected} over @pytest.fixture{actual}
'PT004', # Fixture %s does not return anything, add leading underscore
'PT018', # Assertion should be broken down into multiple parts
'PLR0913', # Too many arguments to function call
'RUF018', # Avoid assignment expressions in `assert` statements
'S101', # Use of assert detected
'SLF001', # Private member accessed
]
'alembic/*' = [
'INP001', # File `%file%` is part of an implicit namespace package. Add an `__init__.py`
'ERA001', # Found commented-out code
]
'alembic/env.py' = [
'F401', # `%s` imported but unused
]
[tool.black]
line-length = 100
target-version = ['py311']
exclude = '''
/(
| \.git
| \.venv
| \.mypy_cache
| \.pytest_cache
| \.ruff_cache
| \.github
)/
'''
skip-string-normalization = true
[tool.mypy]
python_version = '3.12'
show_error_context = true
check_untyped_defs = true
ignore_missing_imports = true
exclude = [
'^.git/',
'^.venv/',
'^.mypy_cache/',
'^.pytest_cache/',
'^.ruff_cache/',
'^.github/',
]
plugins = ['pydantic.mypy']
[tool.bandit]
exclude_dirs = ['tests',]
[tool.pytest.ini_options]
minversion = '8.2'
addopts = '-s --dup-fixtures'
asyncio_mode = 'auto'
asyncio_default_fixture_loop_scope = 'function'
testpaths = ['tests',]
[tool.poetry]
name = 'starlab'
version = '0.1.0'
description = 'My test task'
authors = ['Sanchoyzer <[email protected]>']
readme = 'README.md'
repository = 'https://github.com/Sanchoyzer/starlab'
[tool.poetry.dependencies]
python = '^3.12'
aiohttp = '^3.8.6'
aiohttp-pydantic = '^2.0.0'
pydantic-settings = '^2.1.0'
sentry-sdk = '^2.10.0'
sqlalchemy = {extras = ['asyncio'], version = '^2.0.23'}
asyncpg = '^0.29.0'
gunicorn = '^23.0.0'
alembic = '^1.12.1'
alembic-postgresql-enum = '^1.1.2'
openpyxl = '^3.1.2'
[tool.poetry.group.dev.dependencies]
ruff = '^0.6.0'
black = '^24.8.0'
bandit = '^1.7.5'
mypy = '^1.7.0'
types-setuptools = '^75.1.0.20240917'
types-pygments = '^2.16.0.1'
types-colorama = '^0.4.15.12'
[tool.poetry.group.test.dependencies]
faker = '^29.0.0'
pytest = '^8.3.1'
pytest-sugar = '^1.0.0'
pytest-cov = '^5.0.0'
pytest-repeat = '^0.9.1'
pytest-aiohttp = '^1.0.5'
pytest-asyncio = '^0.24.0'
pytest-randomly = '^3.15.0'
pytest-deadfixtures = '^2.2.1'
[tool.poetry.group.test_performance.dependencies]
locust = '^2.20.0'
[build-system]
requires = ['poetry-core']
build-backend = 'poetry.core.masonry.api'