51 lines
2.5 KiB
Markdown
51 lines
2.5 KiB
Markdown
|
|
# Building and validating a release
|
||
|
|
|
||
|
|
The source archive, Python wheels and standalone CLI are separate artifacts.
|
||
|
|
Python wheels contain `pheon` and its shared library; Cargo installation contains
|
||
|
|
the CLI. Neither installation searches for the other.
|
||
|
|
|
||
|
|
Build the source archive and then the wheel from that archive:
|
||
|
|
|
||
|
|
```sh
|
||
|
|
python -m pip install build
|
||
|
|
python -m build
|
||
|
|
```
|
||
|
|
|
||
|
|
The default `build` invocation builds its wheel from the source archive. Both
|
||
|
|
carry the Cargo version, license and locked dependency resolution. A source build
|
||
|
|
requires Rust 1.88 or newer. The checkout selects current stable through
|
||
|
|
`rust-toolchain.toml`; `RUSTUP_TOOLCHAIN=1.88.0` selects the minimum compiler
|
||
|
|
explicitly for source-package builds. An installed wheel has no Rust runtime
|
||
|
|
requirement.
|
||
|
|
|
||
|
|
The package workflow builds the archive once, then uses cibuildwheel to build
|
||
|
|
from it and repair wheels for Linux x86-64/ARM64, macOS x86-64/ARM64 and Windows
|
||
|
|
x86-64. Repair uses the platform tools supplied by cibuildwheel. Wheels must keep
|
||
|
|
the `py3-none` interpreter/ABI tags and a platform tag, including an appropriate
|
||
|
|
manylinux tag for Linux releases. Local unrepaired `linux_*` wheels are development
|
||
|
|
artifacts, not portable Linux releases.
|
||
|
|
|
||
|
|
Each repaired wheel is tested on Python 3.11 through 3.14 without rebuilding it.
|
||
|
|
Tests run in isolated mode against the installed package and bundled library,
|
||
|
|
including an import that verifies integer packing does not import PyArrow. To
|
||
|
|
repeat that check locally after installing a wheel and PyArrow:
|
||
|
|
|
||
|
|
```sh
|
||
|
|
python -I /path/to/pheon/tools/check_installed.py
|
||
|
|
```
|
||
|
|
|
||
|
|
Unset `PHEON_LIBRARY` for artifact tests. It exists to select an explicit external
|
||
|
|
library during development, and version checks apply equally to that library.
|
||
|
|
The minimum Rust compiler and current stable compiler run native tests in both
|
||
|
|
debug and release modes. CLI artifacts contain the executable, license, README
|
||
|
|
and Git integration templates. They are tied to their build OS and architecture.
|
||
|
|
|
||
|
|
Workflows upload build artifacts only. They do not publish to PyPI, crates.io,
|
||
|
|
or a hosted release. The repository URL and checkout directory can be renamed
|
||
|
|
to `pheon` separately; no remote repository settings are changed by this work.
|
||
|
|
|
||
|
|
The project rename provides no Python import shim or old CLI alias. Companion
|
||
|
|
releases must migrate their imports and dependencies together. The Python C API
|
||
|
|
version and Arrow layout version are currently 1. CLI reports use schema version
|
||
|
|
1 and retain the `klamath-object-v2` comparison profile and existing GDS layer-name
|
||
|
|
metadata marker.
|