-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
144 lines (119 loc) · 2.82 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
142
143
144
[tool.poetry]
name = "homematch"
version = "0.1.0"
description = ""
authors = ["Your Name <[email protected]>"]
readme = "README.md"
[tool.poetry.dependencies]
python = "^3.10"
lancedb = "^0.6.1"
transformers = "^4.38.2"
scrapy = "^2.11.1"
ipykernel = "^6.29.3"
pillow = "^10.2.0"
pandas = "^2.2.1"
datasets = "^2.18.0"
torch = "^2.2.1"
gradio = "^4.20.1"
[tool.poetry.group.dev.dependencies]
pre-commit = "^3.6.2"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.pytest.ini_options]
minversion = "6.0"
addopts = "-ra -q"
testpaths = ["tests/unit"]
filterwarnings = ["ignore::DeprecationWarning"]
[tool.isort]
# Black Compatibility
profile = "black"
#####
# Typing
#####
[tool.mypy]
python_version = "3.11"
warn_return_any = true
warn_unused_configs = true
ignore_missing_imports = true
exclude = ["docs", "notebooks"]
#####
# Flake8 wrapper with pyproject.toml support
#####
[tool.flakeheaven]
exclude = ["README.md"]
# format = "colored"
# nicer output
format = "grouped"
max_line_length = 50
show_source = true
extend-ignore = "E203, W503"
extended_default_ignore = []
[tool.flakeheaven.plugins]
flake8-bandit = ["+*", "-S322"]
flake8-bugbear = ["+*"]
flake8-builtins = [
"+*",
"-A003", # Shadowing a python builtin method
]
flake8-comprehensions = ["+*"]
flake8-docstrings = ["-*"]
flake8-eradicate = ["+*"]
flake8-isort = ["+*"]
flake8-mutable = ["+*"]
flake8-pytest-style = ["+*"]
flake8-spellcheck = ["-*"]
mccabe = ["+*"]
pep8-naming = ["+*"]
pycodestyle = [
"+*",
"-E501", # line-too-long
"-E203", # whitespace-before-colon
"-W503", # line-break-before-binary-operator
"-W504", # line-break-after-binary-operator
]
pyflakes = ["+*"]
pylint = ["+*"]
#####
# Coverage config
#####
[tool.coverage.run]
branch = true
# List of file patterns to ignore
omit = ["tests/", "experimentation/", "examples/", "script/"]
source = ["libs/"]
source_pkgs = ["as_worker", "as_common", "as_scheduler", "as_data_ingestion"]
[tool.coverage.report]
fail_under = 70 # Minimum coverage 70%
exclude_lines = [ # List of regular expressions to ignore
"pragma: no cover",
"logger.",
"def __repr__",
]
precision = 0
# Ignore source code that can’t be found
ignore_errors = true
# Don’t report files that have no executable code
skip_empty = true
[tool.coverage.html]
directory = "htmlcov"
# Don’t include files in the report that are 100% covered
skip_covered = true
[tool.ruff]
line-length = 88
[tool.ruff.lint]
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
select = [
"F", #Pyflakes
"B", #flake8-bugbear
"A", #flake8-builtins
"C4", #flake8-comprehensions
"ERA", #eradicate
"I", #isort
"PT", #flake8-pytest-style
"C90", #mccabe
"N", #pep8-naming
"E", #pycodestyle error
"PL", #Pylint
]
ignore = ["A003"]