Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
176 lines (154 loc) · 3.76 KB
/
Copy pathpyproject.toml
File metadata and controls
176 lines (154 loc) · 3.76 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
[project]
name = "common-knowledge"
version = "0.1.0"
description = "Bürokratt Common-Knowledge Python services"
requires-python = "==3.12.10"
dependencies = []
[project.optional-dependencies]
cleaning = [
"fastapi==0.115.12",
"uvicorn==0.34.2",
"unstructured[docx,doc,pptx,md]==0.18.5",
"pydantic-settings==2.10.1",
"beautifulsoup4==4.13.4",
"langdetect==1.0.9",
"trafilatura==2.0.0",
"markdownify==0.14.1",
"openai==1.82.0",
"pymupdf4llm==0.0.17",
"PyMuPDF==1.25.5",
"requests==2.32.4",
"python-pptx==1.0.2",
"python-docx==1.2.0",
"hvac==2.3.0",
]
scrapper = [
"scrapy==2.13.2",
"fastapi==0.115.12",
"uvicorn==0.34.2",
"celery==5.5.3",
"pydantic-settings==2.10.1",
"scrapy-playwright==0.0.43",
"fake-useragent==2.2.0",
"beautifulsoup4==4.13.4",
]
scheduler = [
"fastapi==0.115.12",
"uvicorn==0.34.2",
"croniter==6.0.0",
]
data-export = [
"fastapi==0.115.12",
"psycopg2-binary==2.9.10",
"uvicorn==0.34.2",
"pydantic-settings==2.10.1",
]
file-processing = [
"fastapi==0.115.12",
"uvicorn==0.34.2",
"pydantic-settings==2.10.1",
"boto3==1.34.0",
"python-multipart==0.0.6",
"psycopg2-binary==2.9.10",
"requests==2.32.4",
"PyYAML==6.0.2",
]
[dependency-groups]
dev = [
"ruff==0.13.3",
"pyright==1.1.405",
"pre-commit==4.3.0",
"pytest==8.3.5",
"pytest-cov==6.0.0",
"pytest-timeout==2.3.1",
"hvac==2.3.0",
"loguru==0.7.3",
"requests==2.32.4",
]
[tool.uv]
package = false
[tool.ruff]
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".ipynb_checkpoints",
".mypy_cache",
".nox",
".pants.d",
".pyenv",
".pytest_cache",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
".vscode",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"site-packages",
"venv",
# Sibling Bürokratt language services that share this working tree
# but ship from their own repos.
"Authentication-Layer",
"CronManager",
"DataMapper",
"Resql",
"Ruuter",
"TIM",
# Local exploration / scratch helpers (untracked).
".ckb-playwright",
]
line-length = 88
indent-width = 4
target-version = "py312"
fix = false
[tool.ruff.lint]
select = ["E4", "E7", "E9", "F", "B", "T20", "N", "ANN", "ERA", "PERF"]
ignore = []
fixable = ["ALL"]
unfixable = []
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"
docstring-code-format = false
docstring-code-line-length = "dynamic"
[tool.pyright]
pythonVersion = "3.12.10"
venvPath = "."
venv = ".venv"
include = ["cleaning", "data-export", "file-processing", "scheduler", "scrapper"]
exclude = [
"**/.venv", "**/__pycache__", "build", "dist", ".git",
".ruff_cache", ".mypy_cache", "tests/", "**/tests/",
]
# Each service runs with its own dir on PYTHONPATH at runtime (Dockerfile WORKDIR
# = /app, then COPY <service>/ /app/), so `from api.models import ...` resolves
# inside the service. A single global extraPaths would make pyright pick the wrong
# `api/models.py` (alphabetically first) for services that share module names like
# `api`. Per-service executionEnvironments scope each service's PYTHONPATH locally.
typeCheckingMode = "standard"
[[tool.pyright.executionEnvironments]]
root = "cleaning"
extraPaths = ["cleaning"]
[[tool.pyright.executionEnvironments]]
root = "data-export"
extraPaths = ["data-export"]
[[tool.pyright.executionEnvironments]]
root = "file-processing"
extraPaths = ["file-processing"]
[[tool.pyright.executionEnvironments]]
root = "scheduler"
extraPaths = ["scheduler"]
[[tool.pyright.executionEnvironments]]
root = "scrapper"
extraPaths = ["scrapper"]