Skip to content

Conversation

rkuester
Copy link
Contributor

@rkuester rkuester commented Sep 30, 2025

Add build configuration for Python 3.12 and 3.13 to the PyPI package.
Update the BUILD file with new compatibility tags and config settings,
extend pypi_build.sh to accept the new Python versions, and add build
steps in the GitHub Actions workflow.

Fix whl_test.sh to rename wheels with unstamped variable names before
pip installation. The py_wheel rule creates the base :whl target with
literal stamp variables like BUILD_EMBED_LABEL in the filename for
Bazel caching purposes. Pip 25.x, which ships with Python 3.12+,
strictly validates wheel filenames and rejects these as invalid version
specifiers. Use sed to replace the unstamped variables with a valid
placeholder version (0.0.0) for testing purposes.

Python 3.14 support is not included because Python 3.14 has not yet
been released (scheduled for October 2025).

BUG= Fixes: #3186

@rkuester
Copy link
Contributor Author

@veblush, can you (since you have write access to the repo and I don't) please manually trigger the PyPI Build GitHub Actions workflow on this branch to test whether it works?

@rkuester rkuester changed the title feat(pypi): add support for Python 3.12, 3.13, and 3.14 feat(pypi): add support for Python 3.12 and 3.13 Sep 30, 2025
@TFLM-bot TFLM-bot removed the ci:run label Sep 30, 2025
Add build configuration for Python 3.12 and 3.13 to the PyPI package.
Update the BUILD file with new compatibility tags and config settings,
extend pypi_build.sh to accept the new Python versions, and add build
steps in the GitHub Actions workflow.

Fix whl_test.sh to rename wheels with unstamped variable names before
pip installation. The py_wheel rule creates the base :whl target with
literal stamp variables like _BUILD_EMBED_LABEL_ in the filename for
Bazel caching purposes. Pip 25.x, which ships with Python 3.12+,
strictly validates wheel filenames and rejects these as invalid version
specifiers. Use sed to replace the unstamped variables with a valid
placeholder version (0.0.0) for testing purposes.

Python 3.14 support is not included because Python 3.14 has not yet
been released (scheduled for October 2025).

Fixes: tensorflow#3186
@rkuester
Copy link
Contributor Author

rkuester commented Oct 2, 2025

This has CI changes which succeeded in a manually-initiated action on this PR's branch:

https://github.com/tensorflow/tflite-micro/actions/runs/18142246787

It's ready to merge.

@rkuester rkuester marked this pull request as ready for review October 2, 2025 17:56
@rkuester rkuester requested review from veblush and a team as code owners October 2, 2025 17:56
@rkuester rkuester added the ci:run label Oct 2, 2025
@TFLM-bot TFLM-bot removed the ci:run label Oct 2, 2025
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.

Python package tflite-micro no longer works in Colab
3 participants