Skip to content

release: fix aarch64-linux + drop macos-13 + idempotent publish#65

Merged
k15z merged 4 commits into
mainfrom
fix-release-workflow
Apr 7, 2026
Merged

release: fix aarch64-linux + drop macos-13 + idempotent publish#65
k15z merged 4 commits into
mainfrom
fix-release-workflow

Conversation

@k15z

@k15z k15z commented Apr 7, 2026

Copy link
Copy Markdown
Owner

Summary

Recovery of the aborted v0.0.2 patch release exposed three pre-existing issues in release.yml:

  1. macos-13 retired — GitHub dropped the macos-13 runner image, so build-wheels (macos-13, x86_64-apple-darwin) fails with `The configuration 'macos-13-us-default' is not supported`. This PR drops that matrix entry; Intel Mac users fall back to the sdist.
  2. aarch64-linux before-script — `dnf install -y openssl-devel perl-IPC-Cmd` was running on the Ubuntu host instead of inside the manylinux_2_28 container for the aarch64 cross-compile, failing with `dnf: command not found` and `docker exit 127`. Switched to `apt-get install -y perl libssl-dev` so it works on the host. (x86_64 still uses `dnf` because its before-script does run inside the container.)
  3. Non-idempotent publish — after the partial v0.0.2 release, `hexchess-zero@0.0.2` is now live on npm but not on PyPI. Any re-run would blow up at `publish-npm` with a 403 on the duplicate version. Both publish jobs now check for the already-published version and skip if present, so recovery runs are idempotent and the path opens to `finalize`.

Also in this PR

  • New `dry_run` workflow_dispatch input that gates `publish-pypi`, `publish-npm`, and `finalize`. Lets us exercise the full wheel matrix on a PR branch without cutting a release.
  • `cleanup-dry-run` job deletes the staging branch after a successful dry run (since `finalize`, which normally owns cleanup, is skipped).

Test plan

  • Dry-run this workflow from this PR branch: `gh workflow run release.yml --ref fix-release-workflow -f bump=patch -f dry_run=true`
  • All 4 wheel targets + sdist + wasm build green
  • After merge, real run: `gh workflow run release.yml -f bump=patch`
  • `publish-npm` detects 0.0.2 on npm, skips; `publish-pypi` actually publishes 0.0.2; `finalize` creates `v0.0.2` tag + release
  • No dangling `release-staging/v0.0.2` branch at the end

k15z added 4 commits April 6, 2026 21:57
… publish

The aborted v0.0.2 release exposed three issues in release.yml:

1. macos-13 runner image has been retired ("macos-13-us-default is not
   supported"). Drop the x86_64-apple-darwin entry; Intel Mac users can
   install from sdist.

2. For aarch64-unknown-linux-gnu the before-script was running `dnf`
   on the Ubuntu host (not inside the manylinux container) and failing
   with exit 127. Switch to `apt-get install -y perl libssl-dev` which
   works on the host.

3. publish-npm and publish-pypi would double-publish on a re-run after
   a partial failure (npm 403s on a duplicate version). Both jobs now
   check for the already-published version and skip the publish step
   if it exists, so recovery runs are idempotent.

Also adds a `dry_run` workflow_dispatch input that gates publish-pypi,
publish-npm, and finalize so we can exercise the full wheel matrix on
a PR branch without cutting a release. A dedicated cleanup-dry-run job
deletes the staging branch after a successful dry run.
aarch64 dry run failed because ort-sys's build script pulls
openssl-sys in transitively (via ureq → native-tls) to download
onnxruntime binaries, and the manylinux cross-compile container
has no aarch64 openssl. Enable the `vendored` feature on `openssl`
for all Linux targets so openssl-sys builds it from source.

Adds ~30s to Linux wheel builds but eliminates the need for a
target-arch openssl install in the cross container.
PyO3/maturin-action#192 documents the working pattern for openssl in
this exact setup: install via the container's native package manager.
The aarch64 container (rust-cross/manylinux_2_28-cross) is Debian-based
and needs \`apt-get install pkg-config libssl-dev\`; the x86_64 container
is AlmaLinux-based and uses \`dnf install openssl-devel perl-IPC-Cmd\`.

The previous attempt (vendored openssl) ran into perl module issues
inside both containers and was the wrong fix — we're not the first
project to ship openssl-dependent wheels via maturin-action.
@k15z k15z merged commit b0c8566 into main Apr 7, 2026
19 checks passed
@k15z k15z deleted the fix-release-workflow branch April 7, 2026 05:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant