Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
136 lines (122 loc) · 3.27 KB
/
Copy pathpyproject.toml
File metadata and controls
136 lines (122 loc) · 3.27 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
[project]
name = "openvols"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
authors = [
{ name = "Brian Curtin", email = "brian.curtin@gmail.com" }
]
requires-python = ">=3.14"
dependencies = [
"asyncpg>=0.31.0",
"black>=26.5.1",
"fastapi[standard]>=0.141.1",
"opentelemetry-api>=1.44.0",
"opentelemetry-distro>=0.65b0",
"opentelemetry-exporter-otlp>=1.44.0",
"opentelemetry-instrumentation-asyncpg>=0.65b0",
"opentelemetry-instrumentation-fastapi>=0.65b0",
"opentelemetry-sdk>=1.44.0",
"phonenumbers>=9.0.37",
"pre-commit>=4.6.1",
"psycopg[binary]>=3.3.4",
"pydantic>=2.13.4",
"pydantic-settings>=2.15.0",
"pytest>=9.1.1",
"pytest-cov>=7.0.0",
"ruff>=0.16.1",
"sendgrid>=6.12.5",
"structlog>=26.1.0",
"twilio>=9.11.0",
"yoyo-migrations>=9.0.0",
]
[project.scripts]
openvols-api = "openvols.api.__main__:main"
openvols-notifications = "openvols.notifications.__main__:main"
[build-system]
requires = ["uv_build>=0.12.2,<0.14.0"]
build-backend = "uv_build"
[dependency-groups]
dev = [
"hypothesis>=6.165.10",
"pytest-asyncio>=1.4.0",
"pytest-env>=1.7.0",
"ruff>=0.16.1",
"ty>=0.0.74",
]
[tool.ruff]
line-length = 100
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
docstring-code-format = false
[tool.ruff.lint]
ignore = [
"F403", # Star imports, which we use intentionally for exporting
]
extend-select = [
"E", # pycodestyle
"F", # pyflakes
"I", # isort
]
[tool.coverage.run]
source = ["src/openvols"]
[tool.coverage.report]
show_missing = true
[tool.pytest.ini_options]
asyncio_mode = "auto"
env = [
"OTEL_SDK_DISABLED = true"
]
[tool.tox]
env_list = [
{ product = [["unit"],["3.14"]] },
{ product = [["data"],["3.14"]] },
{ product = [["ruff"],["3.14"]] },
{ product = [["ty"],["3.14"]] },
]
requires = ["tox-uv"]
[tool.tox.env_base.unit]
description = "Run pytest unit tests"
factors = [["3.14"]]
runner = "uv-venv-lock-runner"
skip_install = true
set_env = {OTEL_SDK_DISABLED = "true"}
deps = [
"pytest>=8",
]
commands = [
["pytest", { replace = "posargs", default = ["tests/unit"], extend = true }]
]
[tool.tox.env_base.data]
description = "Run pytest Postgres tests"
factors = [["3.14"]]
runner = "uv-venv-lock-runner"
skip_install = true
allowlist_externals = ["docker", "./scripts/docker-ready"]
commands_pre = [
["docker", "compose", "up", "-d"],
["./scripts/docker-ready"],
["yoyo", "apply", "-c", { replace = "if", condition = "env.GITHUB_WORKFLOW", then = "yoyo-gh-workflow.ini", "else" = "yoyo-dev.ini"}, "-b"]
]
commands = [
["pytest", { replace = "posargs", default = ["tests/data"], extend = true }]
]
interrupt_post_commands = true # try the post command after a CTRL-C
commands_post = [
["docker", "compose", "down"]
]
[tool.tox.env_base.ruff]
description = "Run the ruff linter"
factors = [["3.14"]]
runner = "uv-venv-lock-runner"
skip_install = true
deps = ["ruff"]
commands = [["ruff", "check", { replace = "posargs", default = ["."], extend = true }]]
[tool.tox.env_base.ty]
description = "Run the ty type checker"
factors = [["3.14"]]
runner = "uv-venv-lock-runner"
skip_install = true
deps = ["ty"]
commands = [["ty", "check", { replace = "posargs", default = ["."], extend = true }]]