-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyproject.toml
175 lines (157 loc) · 3.2 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
[build-system]
requires = ["setuptools>=61.0.0", "wheel", "setuptools_scm"]
build-backend = "setuptools.build_meta"
[project]
name = "memium"
version = "0.25.11"
authors = [{ name = "Martin Bernstorff", email = "[email protected]" }]
description = "Memium"
classifiers = ["Programming Language :: Python :: 3.11"]
requires-python = ">=3.11"
# TODO: https://github.com/MartinBernstorff/memium/issues/260 Setup dependabot automerge
dependencies = [
"cffi==1.17.1",
"iterpy==1.9.0",
"genanki==0.13.1",
"markdown==3.7",
"pydantic==2.10.1",
"sentry-sdk==2.19.0",
"typer==0.13.1",
"tqdm==4.67.1",
"unidecode==1.3.8",
"wasabi==1.1.3",
"bs4==0.0.2",
]
[project.license]
file = "LICENSE"
[project.readme]
file = "readme.md"
content-type = "text/markdown"
[project.scripts]
memium = "memium.__main__:app"
[project.optional-dependencies]
tests = [
"pytest==8.3.3",
"pytest-cov==6.0.0",
"pytest-xdist==3.6.1",
"pytest-sugar==1.0.0",
"pytest-testmon==2.1.1",
"diff-cover==9.2.0",
"syrupy==4.8.0",
]
dev = [
"cruft==2.15.0",
"herbarium",
"invoke==2.2.0",
"pyright==1.1.389",
"pre-commit==4.0.1",
"ruff==0.4.5",
"lumberman",
]
[project.urls]
homepage = "https://github.com/MartinBernstorff/memium"
repository = "https://github.com/MartinBernstorff/memium"
documentation = "https://MartinBernstorff.github.io/memium/"
[tool.pyright]
exclude = [".*venv*", "*subtasks*", ".git", "build"]
pythonPlatform = "Darwin"
reportMissingTypeStubs = false
reportPrivateImportUsage = false
typeCheckingMode = "strict"
[tool.ruff]
# Enable pycodestyle (`E`) and Pyflakes (`F`) codes by default.
line-length = 100
target-version = "py311"
[tool.ruff.lint]
select = [
"A",
"ANN",
"ARG",
"B",
"C4",
"C90",
"COM",
"D417",
"E",
"ERA",
"F",
"I",
"ICN",
"NPY001",
"PD002",
"PIE",
"PLE",
"PLW",
"PT",
"UP",
"PTH",
"RSE",
"RET",
"RUF",
"SIM",
"W",
]
ignore = [
"ANN101",
"ANN401",
"E402",
"E501",
"F841",
"RET504",
"COM812",
"COM819",
"W191",
]
ignore-init-module-imports = true
# Allow autofix for all enabled rules (when `--fix`) is provided.
unfixable = ["ERA"]
# Exclude a variety of commonly ignored directories.
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".hg",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"venv",
"__init__.py",
"docs/conf.py",
]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
[tool.ruff.lint.flake8-annotations]
mypy-init-return = true
suppress-none-returning = true
[tool.ruff.lint.isort]
known-third-party = ["wandb"]
split-on-trailing-comma = false
[tool.ruff.lint.mccabe]
# Unlike Flake8, default to a complexity level of 10.
max-complexity = 10
[tool.ruff.format]
skip-magic-trailing-comma = true
[tool.semantic_release]
branch = "main"
version_toml = ["pyproject.toml:project.version"]
build_command = "python -m pip install build; python -m build"
[tool.setuptools]
include-package-data = true
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
# Ignore lines containing '...'
".*[.]{3}.*",
]
omit = ["test_*.py"]