-
Notifications
You must be signed in to change notification settings - Fork 22
/
Copy pathpyproject.toml
271 lines (251 loc) · 7.07 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
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
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
[project]
name = "codegen"
dynamic = ["version", "urls"]
description = "Scriptable interface to a powerful, multi-lingual language server built on top of Tree-sitter"
readme = "README.md"
# renovate: datasource=python-version depName=python
requires-python = ">=3.12, <3.14"
dependencies = [
"openai==1.64.0",
"tiktoken<1.0.0,>=0.5.1",
"tabulate>=0.9.0,<1.0.0",
"codeowners<1.0.0,>=0.6.0",
"dataclasses-json<1.0.0,>=0.6.4",
"dicttoxml<2.0.0,>=1.7.16",
"xmltodict<1.0.0,>=0.13.0",
"astor<1.0.0,>=0.8.1",
"tree-sitter>=0.23.1",
"tree-sitter-python>=0.23.4",
"tree-sitter-typescript>=0.23.2",
"tree-sitter-javascript>=0.23.1",
"python-levenshtein<1.0.0,>=0.25.1",
"networkx>=3.4.1",
"wrapt<2.0.0,>=1.16.0",
"pyright<2.0.0,>=1.1.372",
"watchfiles<1.1.0,>=1.0.0",
"rich<14.0.0,>=13.7.1",
"pydantic<3.0.0,>=2.9.2",
"pydantic-settings>=2.0.0",
"docstring-parser<1.0,>=0.16",
"plotly>=5.24.0,<7.0.0",
"humanize<5.0.0,>=4.10.0",
"pytest-snapshot>=0.9.0",
"pyjson5==1.6.8",
"mini-racer>=0.12.4",
"rustworkx>=0.15.1",
"typing-extensions>=4.12.2",
"termcolor>=2.4.0",
"sentry-sdk==2.22.0",
"click>=8.1.7",
"requests>=2.32.3",
"lazy-object-proxy>=0.0.0",
"pydantic-core>=2.23.4",
"hatch-vcs>=0.4.0",
"hatchling>=1.25.0",
"pyinstrument>=5.0.0",
"pip>=24.3.1", # This is needed for some NPM/YARN/PNPM post-install scripts to work!
"rich-click>=1.8.5",
"python-dotenv>=1.0.1",
"giturlparse",
"pygit2>=1.16.0",
"unidiff>=0.7.5",
"datamodel-code-generator>=0.26.5",
"PyGithub==2.6.1",
"GitPython==3.1.44",
"psutil>=5.8.0",
"fastapi[standard]<1.0.0,>=0.115.2",
"starlette<1.0.0,>=0.16.0",
"tqdm>=4.67.1",
"tomlkit>=0.13.2",
"python-semantic-release",
"uvicorn[standard]>=0.30.0",
"packaging>=24.2",
"langchain[openai]",
"langchain_core",
"langchain_openai",
"langgraph",
"numpy>=2.2.2",
"mcp[cli]",
"neo4j",
"modal>=0.73.45",
"slack-sdk",
"langchain-anthropic>=0.3.7",
"lox>=0.12.0",
"httpx>=0.28.1",
"docker>=6.1.3",
]
license = { text = "Apache-2.0" }
classifiers = [
"Development Status :: 4 - Beta",
"Environment :: Console",
"Environment :: MacOS X",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"License :: OSI Approved",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Software Development",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Software Development :: Code Generators",
"Topic :: Software Development :: Libraries",
]
authors = [{ name = "Codegen Team", email = "[email protected]" }]
keywords = [
"codegen",
"codebase",
"codebase manipulation",
"codebase analysis",
"codebase transformation",
"refactoring",
"code generation",
]
[project.scripts]
codegen = "codegen.cli.cli:main"
[project.optional-dependencies]
types = [
"types-networkx>=3.2.1.20240918",
"types-tabulate>=0.9.0.20240106",
"types-requests>=2.32.0.20241016",
"types-toml>=0.10.8.20240310",
]
lsp = ["pygls>=2.0.0a2", "lsprotocol==2024.0.0b1", "attrs>=25.1.0"]
[tool.uv]
cache-keys = [{ git = { commit = true, tags = true } }]
dev-dependencies = [
"coverage<8.0.0,>=7.6.1",
# "scalene>=1.5.45",
"filelock<4.0.0,>=3.15.4",
"pytest>=8.3.3",
"pytest-cov>=6.0.0,<6.0.1",
"ruff>=0.6.8",
"mypy[mypyc,faster-cache]>=1.13.0",
"pre-commit>=4.0.1",
"pytest-xdist>=3.6.1,<4.0.0",
"pytest-mock<4.0.0,>=3.14.0",
"pytest-timeout>=2.3.1",
"braintrust>=0.0.160",
"ruff-lsp<1.0.0,>=0.0.55",
"austin-python>=1.7.1",
"autoflake>=2.3.1",
# "nuitka>=2.4.8",
"typer>=0.12.5",
"pre-commit-uv>=4.1.4",
"austin-dist>=3.7.0",
"uv>=0.4.25",
"deptry>=0.22.0",
"cibuildwheel[uv]>=2.22.0",
"sybil[pytest]>=9.0.0",
"jsbeautifier<2.0.0,>=1.15.1",
"inflection<1.0.0,>=0.5.1",
"autoflake>=2.3.1",
"black>=24.8.0",
"isort>=5.13.2",
"emoji>=2.14.0",
"pytest-benchmark[histogram]>=5.1.0",
"pytest-asyncio>=0.21.1,<1.0.0",
"loguru>=0.7.3",
"httpx<0.28.2,>=0.28.1",
"jupyterlab>=4.3.5",
"modal>=0.73.25",
"pytest-lsp>=1.0.0b1",
"cython>=3.0.11",
]
[tool.uv.workspace]
exclude = ["codegen-examples"]
[tool.cython-lint]
max-line-length = 200
[tool.coverage.run]
branch = true
plugins = ["Cython.Coverage"]
concurrency = ["multiprocessing", "thread"]
parallel = true
sigterm = true
[tool.coverage.report]
skip_covered = true
skip_empty = true
exclude_also = [
"if TYPE_CHECKING:",
# Don't complain about missing debug-only code:
"def __repr__",
# Don't complain if tests don't hit defensive assertion code:
"raise AssertionError",
"raise NotImplementedError",
# Don't complain if non-runnable code isn't run:
"if __name__ == .__main__.:",
# Don't complain about abstract methods, they aren't run:
"@(abc\\.)?abstractmethod",
]
[tool.coverage.html]
show_contexts = true
[tool.coverage.json]
show_contexts = true
[tool.pyright]
pythonVersion = "3.12"
enableExperimentalFeatures = true
[tool.pytest.ini_options]
# addopts = -v
pythonpath = "."
norecursedirs = "repos expected"
# addopts = -v --cov=app --cov-report=term
addopts = "--dist=loadgroup --junitxml=build/test-results/test/TEST.xml --strict-config --import-mode=importlib --cov-context=test --cov-config=pyproject.toml -p no:doctest"
filterwarnings = """
ignore::DeprecationWarning:botocore.*:
ignore::DeprecationWarning:sqlalchemy.*:
ignore::DeprecationWarning:posthog.*:"""
log_cli = 1
log_cli_level = "INFO"
xfail_strict = true
junit_duration_report = "call"
junit_logging = "all"
tmp_path_retention_policy = "failed"
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
[build-system]
requires = ["hatchling>=1.26.3", "hatch-vcs>=0.4.0", "setuptools-scm>=8.0.0"]
build-backend = "hatchling.build"
[tool.deptry]
extend_exclude = [".*/eval/test_files/.*.py", ".*conftest.py"]
pep621_dev_dependency_groups = ["types"]
[tool.deptry.per_rule_ignores]
DEP002 = [
"pyright",
"mini-racer",
"hatch-vcs",
"pyinstrument",
"pip",
"python-levenshtein",
"pytest-snapshot",
]
DEP003 = "sqlalchemy"
DEP004 = "pytest"
[tool.deptry.package_module_name_map]
python-levenshtein = ["Levenshtein"]
PyGithub = ["github"]
[tool.cibuildwheel]
build-frontend = "build[uv]"
skip = ["*i686*", "*musllinux*"]
environment = { "HATCH_BUILD_HOOKS_ENABLE" = "true" }
manylinux-x86_64-image = "quay.io/pypa/manylinux_2_34_x86_64"
manylinux-aarch64-image = "quay.io/pypa/manylinux_2_34_aarch64"
[tool.cibuildwheel.linux]
before-all = "curl -sSf https://sh.rustup.rs | sh -s -- -y"
environment = { "PATH" = "$HOME/.cargo/bin:$PATH" }
[tool.semantic_release]
assets = []
build_command_env = []
commit_message = "{version}\n\nAutomatically generated by python-semantic-release"
commit_parser = "angular"
logging_use_named_masks = false
major_on_zero = true
allow_zero_version = true
repo_dir = "."
no_git_verify = false
tag_format = "v{version}"
[tool.semantic_release.branches.develop]
match = "develop"
prerelease_token = "rc"
prerelease = false