-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathpyproject.toml
More file actions
254 lines (223 loc) · 6.5 KB
/
Copy pathpyproject.toml
File metadata and controls
254 lines (223 loc) · 6.5 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
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "asyncmq"
description = "Async task queue with BullMQ-like features"
readme = "README.md"
requires-python = ">=3.10"
dynamic = ['version']
authors = [{ name = "Tiago Silva", email = "tiago@tarsild.io" }]
classifiers = [
"Intended Audience :: Information Technology",
"Intended Audience :: System Administrators",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Software Development :: Libraries :: Application Frameworks",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development",
"Typing :: Typed",
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: AsyncIO",
"Framework :: AnyIO",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Internet :: WWW/HTTP :: HTTP Servers",
"Topic :: Internet :: WWW/HTTP",
]
dependencies = [
"croniter>=6.0.0,<7.0.0",
"lilya[standard]>=0.27.0",
"sayer>=0.7.4",
"redis>=7.0.0",
]
keywords = [
"asyncio",
"anyio",
"task-queue",
"background-jobs",
"job-scheduler",
"rate-limiter",
"dead-letter-queue",
"cron",
"microservices",
"fastapi",
"esmerald",
"ravyn",
"redis",
"postgresql",
"mongodb",
"celery-alternative",
"concurrency",
"parallelism",
"retry-policy",
]
[project.urls]
Homepage = "https://github.com/dymmond/asyncmq"
Documentation = "https://asyncmq.dymmond.com"
Changelog = "https://asyncmq.dymmond.com/release-notes/"
Funding = "https://github.com/sponsors/tarsil"
Source = "https://github.com/dymmond/asyncmq"
[project.scripts]
asyncmq = "asyncmq.cli.__main__:main"
[tool.hatch.version]
path = "asyncmq/__init__.py"
[tool.hatch.envs.default]
dependencies = [
"ty",
"ruff>=0.3.0,<5.0.0",
"pre-commit>=3.3.1,<4.0.0",
"devtools>=0.12.2",
"ipython",
"ipdb",
"ptpython",
"twine",
"types-croniter",
]
[project.optional-dependencies]
testing = [
"fastapi",
"aio_pika>=9.5.5",
"anyio[trio]>=4.9.0,<6.0.0",
"autoflake>=2.0.2,<3.0.0",
"black==24.1.1,<25.0",
"isort>=5.12.0,<6.0.0",
"pytest>=7.2.2,<9.0.0",
"pytest-cov>=4.0.0,<5.0.0",
"pytest-asyncio>=0.26.0",
"pytest-codspeed>=4.3.0",
"structlog>=25.3.0",
"uvicorn>=0.34.2",
"playwright>=1.49.0",
"httpx",
"pyjwt",
"ipdb",
]
postgres = ["asyncpg>=0.30.0"]
mongo = ["motor>=3.7.0"]
aio-pika = ["aio_pika>=9.5.8"]
all = [
"asyncpg>=0.30.0",
"motor>=3.7.0",
"aio_pika>=9.5.8",
]
[tool.hatch.envs.default.scripts]
clean_pyc = "find . -type f -name \"*.pyc\" -delete"
clean_pyi = "find . -type f -name \"*.pyi\" -delete"
clean_pycache = "find . -type d -name \"*__pycache__*\" -delete"
build_with_check = "hatch build; twine check dist/*"
benchmark = "pytest benchmarks/ --codspeed"
benchmark_plan = "python -m benchmarks.plan --json"
benchmark_competitors = "python -m benchmarks.plan --json --require-competitors"
benchmark_prepare = "python -m benchmarks.competitive --targets all --prepare-envs --inventory --json"
benchmark_compare = "python -m benchmarks.competitive --targets asyncmq --inventory --json"
benchmark_load = "python -m benchmarks.load_asyncmq --json"
check_types = "ty check --error-on-warning asyncmq"
lint = "hatch fmt --check -- --exclude docs_src && ty check --error-on-warning asyncmq"
format = "hatch fmt -- --exclude docs_src && hatch fmt --check -- --exclude docs_src && ty check --error-on-warning asyncmq"
[tool.hatch.envs.docs]
dependencies = [
"zensical>=0.0.23,<0.1.0",
"sayer>=0.7.4",
"griffe-typingdoc>=0.2.2,<1.0",
"mkdocs-meta-descriptions-plugin>=2.3.0",
"mkdocstrings>=0.28.3",
"mkdocstrings-python>=2.0.3",
"pyyaml>=6.0,<7.0.0",
"typing_extensions>=3.10.0",
]
[tool.hatch.envs.docs.scripts]
prepare = "scripts/docs.py prepare"
clean = "scripts/docs.py clean"
build = "scripts/docs.py build --clean"
serve = "scripts/docs.py serve"
dev = "scripts/docs.py serve"
update_languages = "scripts/docs.py update-languages"
build_lang = "scripts/docs.py build-lang {args}"
serve_lang = "scripts/docs.py live {args}"
new_lang = "scripts/docs.py new-lang {args}"
[tool.hatch.envs.hatch-test]
features = ["testing", "postgres", "mongo"]
template = "test"
[tool.hatch.envs.hatch-static-analysis]
# disables custom ruff rules, required to align with pre-commit
config-path = "none"
dependencies = ["ruff==0.11.5"]
[tool.hatch.envs.hatch-test.env-vars]
ASYNCMQ_SETTINGS_MODULE = "tests.settings.TestSettings"
LILYA_SETTINGS_MODULE = "tests.settings.LilyaDashboardSettings"
[tool.hatch.envs.test]
features = ['testing']
dependencies = ["ty"]
[tool.hatch.envs.test.scripts]
# needs docker services running
test = "hatch test -- {args}"
test_man = "hatch test -- {args} -s -vv"
check_types = "ty check --error-on-warning asyncmq"
[tool.isort]
profile = "black"
known_third_party = []
src_paths = ["asyncmq"]
[tool.ty]
[tool.ty.environment]
python-version = "3.10"
[tool.ty.terminal]
error-on-warning = true
[tool.ty.rules]
invalid-method-override = "ignore"
unresolved-attribute = "ignore"
unused-type-ignore-comment = "ignore"
[tool.ruff]
line-length = 120
target-version = "py310"
[tool.ruff.lint]
select = ["E", "W", "F", "C", "B", "I"]
ignore = ["E501", "B008", "C901", "B026"]
exclude = ["docs_src/*"]
[tool.ruff.lint.isort]
combine-as-imports = true
[tool.coverage.run]
parallel = true
context = '${CONTEXT}'
source = ["tests", "asyncmq"]
# omit = []
[tool.ty.analysis]
replace-imports-with-any = [
"motor.**",
"asyncpg.**",
"aio_pika",
"aio_pika.**",
"jwt",
"jwt.**",
"lilya.templating.**",
"pymongo",
"pymongo.**",
"redis.**",
]
[tool.pytest.ini_options]
addopts = ["--strict-config", "--strict-markers"]
xfail_strict = true
junit_family = "xunit2"
markers = [
"benchmark: mark a test as a benchmark for CodSpeed",
]
[tool.hatch.build.targets.sdist]
include = ["/asyncmq"]
exclude = [
"/asyncmq/contrib/dashboard/development"
]
[tool.hatch.build.targets.wheel]
include = ["/asyncmq"]
exclude = [
"/asyncmq/contrib/dashboard/development"
]