Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
144 lines (131 loc) · 3.66 KB
/
Copy pathpyproject.toml
File metadata and controls
144 lines (131 loc) · 3.66 KB
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
[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "lamapi"
version = "0.1.0"
description = "A Knowledge-Graph agnostic candidate retriever"
authors = [
{name = "Roberto Avogadro", email = "roberto.avogadro@sintef.no"},
{name = "Federico Belotti", email = "belo.fede@outlook.com"},
]
urls = {Homepage = "https://github.com/enRichMyData/lamapi"}
readme = "README.md"
requires-python = ">=3.9"
license = {text = "MIT"}
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent"
]
dependencies = [
"flask-restx==1.3.0",
"flask-cors==6.0.0",
"gunicorn==23.0.0",
"requests==2.32.4",
"elasticsearch==8.8.1",
"pymongo==4.3.2",
"nltk==3.9.1",
"spacy==3.8.7",
"python-dateutil==2.9.0.post0",
"gevent==24.2.1",
"tqdm",
"pandas",
"SPARQLWRapper",
"python-dotenv",
"column-classifier",
"fastapi>=0.110.0",
"uvicorn[standard]>=0.29.0",
"jsonargparse>=4.27.0",
"pydantic-settings>=2.0.3"
]
[project.scripts]
lamapi = "lamapi.cli:main"
[project.optional-dependencies]
dev = [
"flake8==4.0.1",
"black==21.12b0",
"isort==5.10.0",
"mypy==0.910",
"pre-commit==4.1.0",
"pytest>=7.0.0",
"pytest-asyncio>=0.21.0",
"pytest-cov>=4.0.0",
"pytest-mock>=3.10.0",
]
[tool.setuptools.packages.find]
where = ["."]
include = ["lamapi*", "app*"]
[tool.ruff]
line-length = 99
# Enable Pyflakes `E` and `F` codes by default.
select = [
"E",
"W", # see: https://pypi.org/project/pycodestyle
"F", # see: https://pypi.org/project/pyflakes
"I"
]
ignore = [
"E731", # Do not assign a lambda expression, use a def
"E402", # Module level import not at top of file
]
# Exclude a variety of commonly ignored directories.
exclude = [".git", "docs", "notebooks", "examples", "*.ipynb"]
ignore-init-module-imports = true
# Black formatting
[tool.black]
line_length = 99
include = '\.pyi?$'
exclude = '''
/(
\.eggs # exclude a few common directories in the
| \.git # root of the project
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| _build
| buck-out
| build
| dist
)/
'''
# iSort
[tool.isort]
force_grid_wrap = 0
use_parentheses = true
ensure_newline_before_comments = true
line_length = 99
multi_line_output = 3
include_trailing_comma = true
skip_gitignore = true
[tool.mypy]
# -> Level 1# custom settings
show_error_codes = true
ignore_missing_imports = true
plugins = "numpy.typing.mypy_plugin"
# suggested settings# # https://mypy.readthedocs.io/en/stable/existing_code.html?highlight=no_implicit_optional#introduce-stricter-options
# Start off with these
warn_unused_configs = true
warn_redundant_casts = true
warn_unused_ignores = true
no_implicit_optional = true
# this is for reusing same variable with different types
allow_redefinition = true
# -> Level 2# Getting these passing should be easy
strict_equality = true
strict_concatenate = true
# Strongly recommend enabling this one as soon as you can
check_untyped_defs = true
# -> Level 3# These shouldn't be too much additional work, but may be tricky to get passing if you use a lot of untyped libraries
disallow_subclassing_any = false
disallow_untyped_decorators = false
disallow_any_generics = false
disallow_any_unimported = false
# These next few are various gradations of forcing use of type annotationsdisallow_untyped_calls = false
disallow_incomplete_defs = false
disallow_untyped_defs = false
# -> Level 4# This one isn't too hard to get passing, but return on investment is lower
no_implicit_reexport = false
# This one can be tricky to get passing if you use a lot of untyped libraries
warn_return_any = false