mirror of
https://github.com/pchuan98/codex.git
synced 2026-07-01 00:31:56 +08:00
Use uv as Python SDK build backend (#27901)
## Summary Replace Hatchling with uv's build backend for the Python SDK. The backend infers the `src/openai_codex` module from the normalized project name and standard source layout, so no uv-specific package configuration is required. This keeps Python packaging within the uv toolchain already used for dependency management and release builds. A controlled before-and-after PEP 517 comparison produced identical wheel package paths, bytes, permissions, and semantic metadata. The sdist retains the SDK package tree, root README, and project metadata while dropping the unrelated examples README that Hatch included through its broad include matching.
This commit is contained in:
committed by
GitHub
Unverified
parent
d735ef162f
commit
94427aaf46
@@ -1,6 +1,6 @@
|
||||
[build-system]
|
||||
requires = ["hatchling>=1.27.0"]
|
||||
build-backend = "hatchling.build"
|
||||
requires = ["uv_build>=0.11.19,<0.12"]
|
||||
build-backend = "uv_build"
|
||||
|
||||
[project]
|
||||
name = "openai-codex"
|
||||
@@ -36,28 +36,6 @@ dev = [
|
||||
{ include-group = "format" },
|
||||
]
|
||||
|
||||
[tool.hatch.build]
|
||||
exclude = [
|
||||
".venv/**",
|
||||
".venv2/**",
|
||||
".pytest_cache/**",
|
||||
"dist/**",
|
||||
"build/**",
|
||||
]
|
||||
|
||||
[tool.hatch.build.targets.wheel]
|
||||
packages = ["src/openai_codex"]
|
||||
include = [
|
||||
"src/openai_codex/py.typed",
|
||||
]
|
||||
|
||||
[tool.hatch.build.targets.sdist]
|
||||
include = [
|
||||
"src/openai_codex/**",
|
||||
"README.md",
|
||||
"pyproject.toml",
|
||||
]
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
addopts = "-q"
|
||||
testpaths = ["tests"]
|
||||
|
||||
Reference in New Issue
Block a user