Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
101 lines (91 loc) · 3.22 KB
/
Copy pathpyproject.toml
File metadata and controls
101 lines (91 loc) · 3.22 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
[project]
name = "sqlalchemy-inbox"
version = "0"
description = "Transactional inbox ledger for SQLAlchemy asyncio and PostgreSQL: dedupe consumed messages in the caller's transaction"
authors = [
{ name = "Artur Shiriev", email = "me@shiriev.ru" },
]
readme = "README.md"
requires-python = ">=3.11,<4"
license = "MIT"
keywords = ["sqlalchemy", "inbox", "transactional-inbox", "idempotent-consumer", "postgresql", "asyncio", "python"]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Programming Language :: Python :: 3.15",
"Programming Language :: Python :: Free Threading :: 2 - Beta",
"Typing :: Typed",
"Topic :: Software Development :: Libraries",
]
dependencies = [
# 2.0.31 is the first release that tolerates the __static_attributes__ and __firstlineno__
# attributes Python 3.13 added; below it SQLAlchemy's TypingOnly check fails at import.
# 2.0.20 is the lowest version the tests can verify: db-retry, a dev dependency, requires it.
"sqlalchemy[asyncio]>=2.0.20; python_version < '3.13'",
"sqlalchemy[asyncio]>=2.0.31; python_version == '3.13'",
# 2.0.54 is the first release whose cyextensions declare Py_MOD_GIL_NOT_USED. There is no marker
# for a free-threaded build, so ordinary 3.14 carries the same floor.
"sqlalchemy[asyncio]>=2.0.54; python_version >= '3.14'",
]
[dependency-groups]
dev = [
"pytest>=8",
"pytest-asyncio>=0.24",
"pytest-cov>=5",
"asyncpg>=0.29",
"db-retry>=0.9.1",
]
lint = [
"ruff",
"ty",
"eof-fixer",
]
[build-system]
requires = ["uv_build"]
build-backend = "uv_build"
[tool.uv.build-backend]
module-name = "sqlalchemy_inbox"
module-root = ""
[tool.ruff]
fix = true
unsafe-fixes = true
line-length = 120
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"D1", # docstrings are not forced; a docstring exists when it says something
"D203", # conflicts with D211
"D213", # conflicts with D212
"COM812", # conflicts with the formatter
"ISC001", # conflicts with the formatter
"CPY001", # no per-file copyright header
"FBT", # boolean positional arguments are fine
"TCH", # imports stay real; TYPE_CHECKING-only imports break runtime introspection
]
isort.lines-after-imports = 2
isort.no-lines-before = ["standard-library", "local-folder"]
[tool.ruff.lint.extend-per-file-ignores]
"tests/**" = [
"S101", # allow asserts
"PLR2004", # allow magic values
]
[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = ""
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
[project.urls]
Homepage = "https://modern-python.org"
Repository = "https://github.com/modern-python/sqlalchemy-inbox"
Issues = "https://github.com/modern-python/sqlalchemy-inbox/issues"
Changelog = "https://github.com/modern-python/sqlalchemy-inbox/releases"
[tool.coverage.run]
# SQLAlchemy's async layer runs statements in greenlets; untracked switches drop executed lines.
concurrency = ["greenlet", "thread"]
[tool.coverage.report]
fail_under = 100
exclude_also = ["if typing.TYPE_CHECKING:"]