-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
67 lines (60 loc) · 2.45 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
[tool.poetry]
name = "mc-intent-classifier"
version = "0.1.1.dev0"
description = ""
authors = ["Erik Harding <erik@praekelt.org>"]
readme = "README.md"
repository = "https://github.com/praekeltfoundation/mc-intent-classifier"
packages = [
{ include = "src" },
]
[tool.poetry.dependencies]
python = "^3.11"
gunicorn = "^23.0.0"
flask = "^3.1.0"
prometheus-flask-exporter = "^0.23.1"
flask-basicauth = "^0.2.0"
sentry-sdk = {extras = ["flask"], version = "^2.18.0"}
numpy = "1.23.5"
torch = [
{url = "https://download.pytorch.org/whl/cpu/torch-2.2.2%2Bcpu-cp311-cp311-linux_x86_64.whl", markers = "sys_platform == 'linux'"},
{url = "https://download.pytorch.org/whl/cpu/torch-2.2.2-cp311-none-macosx_10_9_x86_64.whl", markers = "sys_platform == 'darwin'"},
]
sentence-transformers = "^3.1.1"
[tool.poetry.group.dev.dependencies]
ruff = "^0.7.4"
pre-commit = "^4.0.1"
pytest = "^8.3.3"
pytest-mock = "^3.14.0"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff.lint]
select = [
"E", "F", "W", # pycodestyle + pyflakes == flake8 - mccabe
"I", # isort
"UP", # pyupgrade
"S", # flake8-bandit
"B", # flake8-bugbear
"C4", # flake8-comprehensions
# "DJ", # flake8-django
"PIE", # flake8-pie
# "PT", # flake8-pytest-style
"SIM", # flake8-simplify
"PTH", # flake8-use-pathlib
"RUF", # ruff-specific rules
]
ignore = [
"E501", # TODO: Something about these long lines.
"S113", # TODO: Add request timeouts.
"PTH118", # TODO: Switch to pathlib
"PTH100", # TODO: 'os.path.abspath()' should be replaced by 'Path.resolve()' maybe use pathlib?
"PTH120", # TODO: 'os.path.dirname()' should be replaced by 'Path.parent' maybe use pathlib?
"PTH123", # TODO: 'open()' should be replaced by 'Path.open()' maybe use pathlib?
# Ignores below this line needs to be checked out by someone with more knowledge of the project
"S501", #TODO: Probable use of 'requests' call with 'verify=False' disabling SSL certificate checks
"SIM115", # TODO: Use a context manager for opening files - FWB: Tried fixing these, but ran into errors on tests
"S101", # TODO: Use of 'assert' detected - FWB: Looks like this is only used in migration files
"S608", # TODO: Possible SQL injection vector through string-based query construction
"RUF012", # We usually want immutable instance attributes
]