-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpyproject.toml
103 lines (90 loc) · 2.22 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
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "PassBot"
version = "1.0.0"
description = "A collections of bots for French Passeport & co!"
authors = ["Yannick Chabbert <[email protected]>"]
license = "MIT"
readme = "README.md"
[tool.poetry.dependencies]
python = "^3.11"
psycopg2-binary = "^2.9.5"
sqlalchemy = {extras = ["mypy"], version = "^2.0.3"}
alembic = "^1.9.2"
scrapy = "^2.8.0"
pydantic = {extras = ["dotenv", "email"], version = "^1.10.5"}
python-slugify = "^8.0.0"
[tool.poetry.group.test.dependencies]
tox = "^4.4.5"
factory-boy = "^3.2.1"
pytest = "^7.2.1"
pytest-cov = "^4.0.0"
pytest-reverse = "^1.5.0"
[tool.poetry.group.dev.dependencies]
pre-commit = "^3.0.4"
pylama = {extras = ["toml"], version = "^8.4.1"}
isort = "^5.10.1"
mypy = "^1.0.1"
types-python-slugify = "^8.0.0.0"
[tool.pylama]
format = "pylint"
linters = "pycodestyle,pyflakes,mccabe"
skip = ".tox/*,*/alembic/*,*/crawlers/settings.py,*/crawlers/middlewares.py"
[tool.pylama.linter.pycodestyle]
max_line_length = 119
[tool.pylama.linter.mccabe]
complexity = 15
[tool.mypy]
plugins = [
"pydantic.mypy",
"sqlalchemy.ext.mypy.plugin",
]
exclude = [
"alembic",
"middlewares.py",
]
disallow_untyped_defs = true
ignore_missing_imports = true
show_error_codes = true
[[tool.mypy.overrides]]
module = "tests.*"
disallow_untyped_defs = false
disable_error_code = [
"annotation-unchecked",
]
[tool.isort]
src_paths = ["passbot", "tests"]
line_length = 120
combine_as_imports = true
multi_line_output = 5
include_trailing_comma = true
skip = ".tox,alembic"
sections = "FUTURE,STDLIB,FRAMEWORK,THIRDPARTY,FIRSTPARTY,TESTFOLDER,LOCALFOLDER"
known_framework = "scrapy,pydantic,sqlalchemy,alembic,pytest"
known_first_party = "passbot"
known_testfolder = "tests"
[tool.pytest.ini_options]
addopts = "-ra -q"
testpaths = [
"tests",
]
[tool.coverage.run]
source = ["passbot", "tests"]
branch = true
omit = [
"passbot/alembic/*",
"passbot/crawlers/middlewares.py",
"passbot/crawlers/settings.py",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"raise AssertionError",
"raise NotImplementedError",
"def __str__",
"def __repr__",
"pass",
]
precision = 2