Release
Tag-driven CLI + LSP multi-platform Nuitka binaries, wheels, Docker CLI image, VSIX packaging, GitHub Releases, and Marketplace publish.
This page
Release
Abstract
A PYNE release is a multi-artifact event, not a single wheel upload. The primary automation (.github/workflows/release.yml) builds:
- PyPI sdist + wheel (
hoox-pyne) with CLI smoke - CLI platform-native Nuitka binaries (
pynescript) - LSP platform-native Nuitka binaries (
pynescript-lsp) - CLI Docker image tarball (
pynescript-cli-image.tar.gz) - VS Code VSIX
Assets attach to a GitHub Release; PyPI upload is handled by Publish (publish.yml). Multi-arch container images are a separate workflow (GHCR / ghcr.yml) — not attached as tarballs except the CLI image save in this workflow. Marketplace / Open VSX publish is optional via VSCE_PAT / OVSX_PAT.
Conceptual model
Rendering…
Interface surface
Triggers
| Event | Behavior |
|---|---|
Push tag matching v* | Full build + create release + marketplace/Open VSX publish |
workflow_dispatch with version input | Same jobs; Create Release also runs on dispatch (not tag-only) |
Jobs
| Job | Matrix / OS | Output |
|---|---|---|
build-package | ubuntu-latest | hoox-pyne-dist (sdist + wheel) |
build-cli | ubuntu-latest, windows-latest, macos-latest | pynescript-cli-linux-x86_64, …-windows-x86_64.exe, …-macos-arm64 |
build-lsp | ubuntu-latest, windows-latest, macos-latest | pynescript-lsp-linux-x86_64, …-windows-x86_64.exe, …-macos-arm64 |
build-docker-cli | ubuntu-latest | pynescript-cli-docker (gzipped docker save) |
build-vscode | ubuntu-latest | pynescript-vscode-extension VSIX |
release | needs package + vscode success; tag or dispatch | GitHub Release body + staged assets (name: pyne vX.Y.Z) |
publish-vscode | needs VSIX; tag or dispatch | vsce publish if VSCE_PAT; ovsx publish if OVSX_PAT |
Environment
env:
PYTHON_VERSION: "3.11" # Nuitka 2.5–2.7 graph; comment in workflow
NUITKA_JOBS: 4
Build steps rely on:
# LSP
pip install -e ".[lsp]" "nuitka>=2.5.1,<2.8" cryptography
python scripts/build/compile.py --target lsp --no-encrypt --check
python scripts/build/ci_build.py --target lsp --jobs 4
# CRYPTO_KEY from secrets.METADATA_KEY
# CLI
pip install -e . "nuitka>=2.5.1,<2.8"
python scripts/build/compile.py --target cli --check
python scripts/build/ci_build.py --target cli --jobs 4 --skip-metadata --skip-vsix
Local make-side packaging
make package # sdist + wheel (python -m build)
make build # Nuitka LSP
make build-cli # Nuitka CLI
make build-vscode # npm install && compile && vsce package
make docker-build-cli
Artifacts land under dist/, dist/lsp/, dist/cli/, dist/vsix/, and vscode-extension/*.vsix depending on script path.
Internals
| Path | Role |
|---|---|
.github/workflows/release.yml | Orchestration |
scripts/build/ci_build.py | CI-oriented Nuitka + metadata encrypt |
scripts/build/compile.py | Local/full compile options (--onefile, --standalone, --check) |
vscode-extension/package.json | Extension version / engines |
src/pynescript/__about__.py | Hatch dynamic version for Python package |
Release asset contract (from release body)
| Artifact | Install sketch |
|---|---|
hoox_pyne-*.whl / *.tar.gz | pip install ./hoox_pyne-*.whl |
pynescript-cli-linux-x86_64 | chmod +x → /usr/local/bin/pynescript |
pynescript-cli-windows-x86_64.exe | Place on PATH as pynescript.exe |
pynescript-cli-macos-arm64 | Place on PATH (Apple Silicon runners) |
pynescript-cli-image.tar.gz | gunzip -c … | docker load → pynescript-cli:latest |
pynescript-lsp-linux-x86_64 | chmod +x → /usr/local/bin/pynescript-lsp |
pynescript-lsp-windows-x86_64.exe | Place on PATH |
pynescript-lsp-macos-arm64 | Place on PATH (Apple Silicon runners) |
pyne-vscode-*.vsix (hoox-sh.pyne 0.4.4) | code --install-extension pyne-vscode-*.vsix · site: hoox.sh/pyne-vscode.vsix (unversioned) |
Invariants & edge cases
CRYPTO_KEYmust be stable across builds if you care about byte-identicalbuiltin_metadata.json.enc. Supplysecrets.METADATA_KEY.- Tag name is the version source for the GitHub Release title (
vprefix stripped). - Marketplace publish needs
VSCE_PAT. Without it, packaging may still succeed while publish fails. - Artifact retention is short (5 days on build jobs) — releases must attach files immediately.
- macOS artifact is ARM64 from
macos-latest— Intel Mac users may need separate builds if required. - Draft vs prerelease: workflow currently sets
draft: false,prerelease: falsefor tag releases.
Worked examples
Cut a release
# ensure main is green
git checkout main && git pull
# bump versions in extension / __about__ as needed
git tag -a v0.3.14 -m "v0.3.14"
git push origin v0.3.14
# watch Actions → Build & Release, Publish, GHCR
Smoke-test a downloaded binary
chmod +x pynescript-cli-linux-x86_64
./pynescript-cli-linux-x86_64 --help
./pynescript-cli-linux-x86_64 check script.pine
chmod +x pynescript-lsp-linux-x86_64
./pynescript-lsp-linux-x86_64 --help
# or wire stdio into an editor client
Failure modes
| Symptom | Cause | Fix |
|---|---|---|
| Binary not found after Nuitka | Path layout drift in ci_build.py | Inspect dist/; fix finder step |
| Decrypt errors in field | Key mismatch between encrypt and runtime | Align METADATA_KEY with embedded key strategy |
| Empty GitHub Release assets | Artifact download path mismatch | Match files: globs to download-artifact layout |
| Marketplace 401 | Bad/expired VSCE_PAT | Rotate PAT with Marketplace scopes |
Windows .exe not marked executable | Finder uses -type f -executable | Fallback non-executable find branch in workflow |