-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
180 lines (164 loc) · 5.36 KB
/
Copy pathpyproject.toml
File metadata and controls
180 lines (164 loc) · 5.36 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
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
[project]
authors = [{ name = "Alex Glushko", email = "alextvrus@gmail.com" }]
classifiers = [
"Development Status :: 3 - Alpha",
"Environment :: Web Environment",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python",
"Topic :: Software Development",
"Typing :: Typed",
"Intended Audience :: Developers",
"Intended Audience :: System Administrators",
"Topic :: Database",
"Topic :: Database :: Database Engines/Servers",
]
name = "litestar-psycopg"
keywords = ["litestar", "psycopg"]
license = { text = "Apache-2.0" }
version = "0.1.1"
description = "Psycopg plugin for Litestar"
readme = "README.md"
requires-python = ">=3.9"
dependencies = ["litestar>=2.16.0", "psycopg[binary,pool]>=3.2.7"]
[project.urls]
Issue = "https://github.com/kumokage/litestar-psycopg/issues/"
Source = "https://github.com/kumokage/litestar-psycopg"
[dependency-groups]
dev = [
"anyio>=4.9.0",
"coverage>=7.8.0",
"pyright>=1.1.400",
"pytest>=8.3.5",
"pytest-cov>=6.1.1",
"pytest-databases[postgres]>=0.12.3",
"pytest-mock>=3.14.0",
"pytest-sugar>=1.0.0",
"pytest-xdist>=3.6.1",
"ruff>=0.11.9",
]
[build-system]
build-backend = "hatchling.build"
requires = ["hatchling"]
[tool.pytest.ini_options]
addopts = "-ra"
filterwarnings = [
"ignore::DeprecationWarning:pkg_resources",
"ignore::DeprecationWarning:google.*",
"ignore::DeprecationWarning:passlib.*",
"ignore::DeprecationWarning:aiosql.*",
"ignore::DeprecationWarning:litestar.constants.*",
"ignore::DeprecationWarning:litestar.utils.*",
]
testpaths = ["tests"]
[tool.coverage.run]
concurrency = ["multiprocessing"]
omit = ["*/tests/*"]
parallel = true
[tool.coverage.report]
exclude_lines = [
'pragma: no cover',
'if TYPE_CHECKING:',
'except ImportError as e:',
'except ImportError:',
'\.\.\.',
'raise NotImplementedError',
'if VERSION.startswith("1"):',
'if pydantic.VERSION.startswith("1"):',
]
omit = ["*/tests/*"]
show_missing = true
[tool.ruff]
exclude = [".venv"]
line-length = 120
src = ["litestar_psycopg", "tests"]
target-version = "py39"
[tool.ruff.format]
docstring-code-format = true
docstring-code-line-length = 60
[tool.ruff.lint]
extend-safe-fixes = ["TC"]
fixable = ["ALL"]
ignore = [
"A003", # flake8-builtins - class attribute {name} is shadowing a python builtin
"B010", # flake8-bugbear - do not call setattr with a constant attribute value
"D100", # pydocstyle - missing docstring in public module
"D101", # pydocstyle - missing docstring in public class
"D102", # pydocstyle - missing docstring in public method
"D103", # pydocstyle - missing docstring in public function
"D104", # pydocstyle - missing docstring in public package
"D105", # pydocstyle - missing docstring in magic method
"D106", # pydocstyle - missing docstring in public nested class
"D107", # pydocstyle - missing docstring in __init__
"D202", # pydocstyle - no blank lines allowed after function docstring
"D205", # pydocstyle - 1 blank line required between summary line and description
"D415", # pydocstyle - first line should end with a period, question mark, or exclamation point
"E501", # pycodestyle line too long, handled by ruff format
"PLW2901", # pylint - for loop variable overwritten by assignment target
"RUF012", # Ruff-specific rule - annotated with classvar
"ISC001", # Ruff formatter incompatible
"A005", # flake8 - Module `x` shadows a Python standard-library module
"PLC0415", # pylint - `import` should be at the top of the file
"FA100", # Add `from __future__ import annotations` to simplify
"ANN401", # Dynamically typed expressions (typing.Any) are disallowed
"FBT001", # Boolean-typed positional argument in function definition
"FBT002", # Boolean default positional argument in function definition
"PLR0913", # pylint - Too many arguments in function definition
"ARG002", # Unused method argument
"ARG001", # Unused function argument
"CPY001", # pycodestyle - Missing Copywrite notice at the top of the file
"RUF029", # Ruff - function is declared as async but has no awaitable calls
"COM812", # flake8-comma - Missing trailing comma
"PGH003", # Use Specific ignore for pyright
"UP007",
"UP035",
"UP006",
]
select = ["ALL"]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.mccabe]
max-complexity = 18
[tool.ruff.lint.pep8-naming]
classmethod-decorators = ["classmethod"]
[tool.ruff.lint.isort]
known-first-party = ["litestar_psycopg", "tests"]
[tool.ruff.lint.per-file-ignores]
"docs/**/*.*" = ["S", "B", "DTZ", "A", "TC", "ERA", "D", "RET", "PLW0127"]
"docs/examples/**" = ["T201"]
"tests/**/*.*" = [
"A",
"ARG",
"B",
"BLE",
"C901",
"D",
"DTZ",
"EM",
"FBT",
"G",
"N",
"PGH",
"PIE",
"PLR",
"PLW",
"PTH",
"RSE",
"S",
"S101",
"SIM",
"TC",
"TRY",
"PT012",
"INP001",
"DOC",
"PLC",
]
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "all"