Skip to content

rgb-matrix.sh: fix Python bindings build on Trixie#376

Open
mikeysklar wants to merge 1 commit into
adafruit:mainfrom
mikeysklar:fix/trixie-python3-setuptools
Open

rgb-matrix.sh: fix Python bindings build on Trixie#376
mikeysklar wants to merge 1 commit into
adafruit:mainfrom
mikeysklar:fix/trixie-python3-setuptools

Conversation

@mikeysklar
Copy link
Copy Markdown
Contributor

@mikeysklar mikeysklar commented Apr 26, 2026

Python 3.13, shipped with the April 2026 Pi OS Trixie release, removed distutils from the stdlib. The RGB matrix Python bindings build via setup.py, which imports it — so both make clean and make build-python fail:

ModuleNotFoundError: No module named 'distutils'

Fix: add python3-setuptools to the prerequisites apt-get install line. It provides the distutils compatibility shim. The C demo and all C examples are unaffected — only the Python bindings fail without this.

Tested on

Pi Bonnet Panel OS Python Status
Zero 2WH RGB Matrix Bonnet (3211) 64×32 2.5mm (5036) Bookworm 64-bit Lite (Legacy) 3.11 ✅ works, no change needed
Zero 2WH RGB Matrix Bonnet (3211) 64×32 2.5mm (5036) Trixie 64-bit Lite (2026-04-21) 3.13.5 ✅ fixed by this PR

forum issue

…ibility

Python 3.13 (shipped with Debian Trixie / Pi OS Trixie) removed distutils
from the stdlib. The Python bindings build via setup.py, which imports
distutils.core — causing both make clean and make build-python to fail with
ModuleNotFoundError: No module named 'distutils'.

Adding python3-setuptools to the prerequisites apt-get install line provides
the distutils compatibility shim and restores the Python bindings build.

The C demo and all C examples are unaffected; this only impacts the Python
bindings.

Tested on Pi Zero 2WH + Adafruit RGB Matrix Bonnet (3211), Convenience mode,
Debian Trixie 13.4 / Pi OS (64-bit) April 2026 release.
@mikeysklar mikeysklar marked this pull request as ready for review April 26, 2026 21:44
@mikeysklar mikeysklar changed the title rgb-matrix.sh: fix Python bindings build on Trixie (Python 3.13 dropped distutils) rgb-matrix.sh: fix Python bindings build on Trixie Apr 26, 2026
@ladyada ladyada requested a review from caternuson April 27, 2026 14:35
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