Split out of #314, which deliberately excludes the Python wheels from the release assets for this reason.
The bug
python-package in .github/workflows/release.yml builds a wheel per platform across a four-entry matrix, but the platform tag never reaches the wheel:
matrix.plat_name (macosx_14_0_arm64, manylinux_2_17_x86_64, manylinux_2_17_aarch64, win_amd64) is referenced nowhere in the job body.
- The step captioned "Re-tag the wheel with the correct platform" only iterates
glob.glob('dist/*.whl') and prints the filenames. It re-tags nothing.
The package has no ext modules, so setuptools emits offline_protocol_sdk-<version>-py3-none-any.whl for all four. One filename, four different native libraries.
Consequences:
- The four
python-wheel-* artifacts each contain an identically-named wheel. Attaching them to a release would collide on upload.
- Any one of them that landed would be a wheel
pip installs happily on the wrong platform, producing a load failure at import rather than a resolver error at install.
manylinux_2_17_* is also inaccurate independent of the tagging: the Linux libraries are built on ubuntu-latest, so they carry that image's glibc floor, not 2.17.
Fix sketch
Set the tag at build time rather than after the fact — either python -m build --wheel -C--build-option=--plat-name=${{ matrix.plat_name }}, or wheel tags --platform-tag on the built artifact, or a bdist_wheel subclass with root_is_pure = False. Whichever route, the job needs an assertion that the emitted filename actually carries the tag, since the current failure mode is a silently-wrong wheel.
For the glibc claim: either build in a manylinux container so manylinux_2_17 is true, or tag with the floor the ubuntu-latest build actually produces.
Blocks
Attaching Python wheels to the GitHub release. Everything else shipped in #314.
Split out of #314, which deliberately excludes the Python wheels from the release assets for this reason.
The bug
python-packagein.github/workflows/release.ymlbuilds a wheel per platform across a four-entry matrix, but the platform tag never reaches the wheel:matrix.plat_name(macosx_14_0_arm64,manylinux_2_17_x86_64,manylinux_2_17_aarch64,win_amd64) is referenced nowhere in the job body.glob.glob('dist/*.whl')andprints the filenames. It re-tags nothing.The package has no ext modules, so setuptools emits
offline_protocol_sdk-<version>-py3-none-any.whlfor all four. One filename, four different native libraries.Consequences:
python-wheel-*artifacts each contain an identically-named wheel. Attaching them to a release would collide on upload.pipinstalls happily on the wrong platform, producing a load failure at import rather than a resolver error at install.manylinux_2_17_*is also inaccurate independent of the tagging: the Linux libraries are built onubuntu-latest, so they carry that image's glibc floor, not 2.17.Fix sketch
Set the tag at build time rather than after the fact — either
python -m build --wheel -C--build-option=--plat-name=${{ matrix.plat_name }}, orwheel tags --platform-tagon the built artifact, or abdist_wheelsubclass withroot_is_pure = False. Whichever route, the job needs an assertion that the emitted filename actually carries the tag, since the current failure mode is a silently-wrong wheel.For the glibc claim: either build in a
manylinuxcontainer somanylinux_2_17is true, or tag with the floor theubuntu-latestbuild actually produces.Blocks
Attaching Python wheels to the GitHub release. Everything else shipped in #314.