-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
133 lines (117 loc) · 3.83 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
[tool.poetry]
name = "fastapi_factory_utilities"
homepage = "https://github.com/miragecentury/fastapi_factory_utilities"
repository = "https://github.com/miragecentury/fastapi_factory_utilities"
keywords = ["python", "fastapi", "beanie", "httpx", "opentelemetry", "microservices"]
version = "0.1.0"
description = "Consolidate libraries and utilities to create microservices in Python with FastAPI, Beanie, Httpx, AioPika and OpenTelemetry."
authors = ["miragecentury <victorien.vanroye@gmail.com>"]
maintainers = ["miragecentury <victorien.vanroye@gmail.com>"]
license = "MIT"
readme = "README.md"
packages = [
{ include = "fastapi_factory_utilities", from = "src" },
]
classifiers = [
"Programming Language :: Python :: 3.12",
"Development Status :: 3 - Alpha",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Intended Audience :: Developers",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Software Development :: Libraries :: Application Frameworks",
]
[tool.poetry.dependencies]
python = "~3.12"
structlog = "^24.1.0"
typer = "^0.15.1"
pydantic = "^2.8.2"
fastapi = "^0.115.4"
uvicorn = "^0.32.0"
opentelemetry-sdk = "^1.26.0"
opentelemetry-exporter-otlp-proto-http = "^1.26.0"
httpx = "^0.28.1"
opentelemetry-instrumentation-fastapi = "^0.49b1"
opentelemetry-propagator-b3 = "^1.26.0"
beanie = "^1.27.0"
opentelemetry-instrumentation-pymongo = "^0.49b2"
pymongo = "~4.9.2" # version fixed to fix integration between beanie and pytest-mongo
[tool.poetry.group.test]
optional = true
[tool.poetry.group.test.dependencies]
mypy = "^1.10.0"
types-requests = "^2.32.0.20240712"
types-pyyaml = "^6.0.12.20240311"
pylint = {version="^3.2.2", extras=["spelling"]}
black = "^24.4.2"
pre-commit = "^4.0.1"
pyupgrade = "^3.15.2"
pytest = "^8.2.0"
pytest-xdist = "^3.6.1"
pytest-cov = "^6.0.0"
ruff = "^0.7.2"
pytest-asyncio = "^0.25.0"
pytest-mongo = "^3.1.0"
locust = "^2.32.4"
testcontainers = { version="^4.9.0", extras=["mongodb"] }
types-deprecated = "^1.2.15.20241117"
types-pygments = "^2.18.0.20240506"
types-colorama = "^0.4.15.20240311"
types-protobuf = "^5.29.1.20241207"
types-psutil = "^6.1.0.20241221"
types-pyopenssl = "^24.1.0.20240722"
types-ujson = "^5.10.0.20240515"
[tool.poetry.extras]
[tool.poetry.scripts]
fastapi_factory_utilities-example = "fastapi_factory_utilities.example.__main__:main"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.pytest.ini_options]
addopts = "tests/units tests/integrations -n auto --color=yes --import-mode=importlib"
filterwarnings = [
"ignore:.*Type google._upb._message.MessageMapContainer:DeprecationWarning",
"ignore:.*Type google._upb._message.ScalarMapContainer:DeprecationWarning",
"ignore:.*pkg_resources is deprecated as an API.:DeprecationWarning",
]
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "session"
mongo_params = ""
[tool.black]
line-length = 120
target-version = ['py312']
[tool.isort]
profile = "black"
[tool.mypy]
python_version = "3.12"
warn_unused_configs = true
packages = "fastapi_factory_utilities"
mypy_path = "src:tests"
namespace_packages = true
plugins = ["pydantic.mypy"]
follow_imports = "silent"
warn_redundant_casts = true
warn_unused_ignores = true
disallow_any_generics = true
check_untyped_defs = true
no_implicit_reexport = true
# for strict mypy: (this is the tricky one :-))
disallow_untyped_defs = true
[tool.pydantic-mypy]
init_forbid_extra = true
init_typed = true
warn_required_dynamic_aliases = true
[tool.ruff]
# Same as Black.
line-length = 120
indent-width = 4
[tool.ruff.lint]
select = ["D","F","E","W","I","UP","PL","N","RUF"]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
docstring-code-format = true
docstring-code-line-length = 120
[tool.ruff.lint.pydocstyle]
convention = "google"