-
Notifications
You must be signed in to change notification settings - Fork 485
/
Copy pathpyproject.toml
183 lines (164 loc) · 4.57 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
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
[project]
name = "invoice2data"
authors = [{ name = "Manuel Riel" }]
description = "Python parser to extract data from pdf invoice"
version = "0.4.5"
keywords = ["python", "data-mining", "accounting", "invoice", "pdf", "parcing"]
license = { text = "MIT" }
readme = "README.md"
requires-python = ">=3.8"
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Office/Business :: Financial",
"Topic :: Office/Business :: Financial :: Accounting",
"Environment :: Console",
"Intended Audience :: Financial and Insurance Industry",
"Intended Audience :: Developers",
"Topic :: Office/Business :: Financial :: Accounting",
"Topic :: Office/Business :: Financial",
"Topic :: Software Development :: Libraries :: Python Modules",
"Development Status :: 5 - Production/Stable",
]
dependencies = [
"click >=8.0.1",
"dateparser >= 1.2.0",
"PyYAML >= 6.0",
"regex >= 2024.4.16",
]
[project.urls]
homepage = "https://github.com/invoice-x/invoice2data"
repository = "https://github.com/invoice-x/invoice2data"
documentation = "https://invoice2data.readthedocs.io"
Changelog = "https://github.com/invoice-x/invoice2data/releases"
[dependency-groups]
dev = [
"coverage[toml] >= 6.0",
"pre-commit >=2.16.0",
"pre-commit-hooks >=4.1.0",
"pytest >=8.2.2",
"pytest-mock >= 3.14.0",
"pygments >=2.10.0",
]
lint = ["ruff >=0.5.1", "pydoclint >=0.4.2"]
docs = [
"furo >=2021.11.12",
"myst-parser == 3.0.1",
"sphinx >= 4.3.2",
"sphinx-autobuild >=2021.3.14",
"sphinx-click >=3.0.2",
"sphinx-mermaid >=0.0.7",
]
mypy = ["mypy >=0.930"]
safety = ["safety >=2.2.3"]
typeguard = ["typeguard >=2.13.3"]
xdoctest = ["xdoctest[colors] >=0.15.10"]
[project.optional-dependencies]
defusedxml = ["defusedxml == 0.7.1"]
dev = [
"pygments == 2.18.0",
"cffi == 1.17.1",
"furo == 2024.5.6",
"mypy == 1.10.1",
"myst-parser == 3.0.1",
"pre-commit == 3.5.0",
"pre-commit-hooks == 4.6.0",
# "pytest-mock >= 3.14.0",
"safety == 3.2.4",
"sphinx == 7.1.2",
"sphinx-autobuild == 2021.3.14",
"sphinx-click == 6.0.0",
"typeguard == 4.3.0",
"xdoctest >=0.15.10",
]
googlevision = [
"google-cloud-storage == 2.18.2",
"google-cloud-vision == 3.8.1",
]
ocr = ["ghostscript == 0.7"]
ocrmypdf = ["ocrmypdf >= 14.4.0"]
pdfminer-six = ["pdfminer-six == 20231228"]
pdfplumber = ["pdfplumber == 0.11.4"]
pyyaml = ["pyyaml == 6.0.2"]
[tool.uv]
package = true
[project.scripts]
invoice2data = "invoice2data.__main__:main"
[tool.coverage.paths]
source = ["src", "*\\src", "*/site-packages"]
tests = ["tests", "*/tests"]
[tool.coverage.run]
branch = true
source = ["invoice2data", "tests"]
[tool.coverage.report]
show_missing = true
fail_under = 75
exclude_lines = ["pragma: no cover", "if TYPE_CHECKING:"]
[tool.ruff.lint.isort]
force-single-line = true
lines-after-imports = 2
[tool.mypy]
strict = true
warn_unreachable = true
pretty = true
show_column_numbers = true
show_error_context = true
[tool.ruff]
src = ["src", "tests"]
[tool.ruff.lint]
extend-select = [
"B", # flake8-bugbear
"C90", # mccabe
"D", # pydocstyle
"E", # pycodestyle
"F", # pyflakes
"I", # isort
"N", # pep8-naming
"RUF", # Ruff-specific rules
"S", # flake8-bandit
"UP", # pyupgrade
"W", # pycodestyle
]
# ignore checks that conflict with ruff formatter (https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules)
extend-ignore = [
"COM812",
"COM819",
"D107", # undocumented-public-init conflicts with DOC301
"D206",
"D300",
"E111",
"E114",
"E117",
"ISC001",
"ISC002",
"Q000",
"Q001",
"Q002",
"Q003",
"W191",
"RUF013", # activate after implement typing
"D103", # fix docstrings in public functions later
"S101", # use of assert Activate later
"S603",
"UP031", # Use fstring instead of % identifier
"E501", # fix this when updating docstrings
# "DOC106",
# "DOC107",
# "DOC111",
]
[tool.ruff.lint.per-file-ignores]
"*/test_*.py" = ["S101", "D100", "D101", "D102"]
"noxfile.py" = ["S101"]
"**/conftest.py" = ["S101"]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.pydoclint]
style = 'google'
exclude = '\.git|\.nox|tests*|noxfile.py|tables.py'
arg-type-hints-in-docstring = true