Skip to content

Drop Python 3.9, use 3.10 for dist, bump Ledger#819

Open
Sjors wants to merge 11 commits intobitcoin-core:masterfrom
Sjors:2026/01/python-bump
Open

Drop Python 3.9, use 3.10 for dist, bump Ledger#819
Sjors wants to merge 11 commits intobitcoin-core:masterfrom
Sjors:2026/01/python-bump

Conversation

@Sjors
Copy link
Member

@Sjors Sjors commented Jan 21, 2026

This PR first switches the deterministic builds to Python 3.10. It then drops the end-of-life 3.9.

Then it bumps Speculos and Ledger and enables the tests that were previously disabled.

There's also a few minor cleanup commits, plus changes to make the Docker containers Podman friendly so I can easily run them locally.

@Sjors Sjors force-pushed the 2026/01/python-bump branch 2 times, most recently from 8489c74 to 57f6690 Compare January 23, 2026 09:21
@Sjors Sjors force-pushed the 2026/01/python-bump branch from 57f6690 to a608ea3 Compare January 30, 2026 10:00
@Sjors Sjors marked this pull request as ready for review January 30, 2026 10:01
@Sjors
Copy link
Member Author

Sjors commented Jan 30, 2026

Rebased after #818 landed, ready for review.

I lightly tested the dist builds on Ubuntu (x86_64, including qt) and macOS (only command line).

I ran the GUI in Wine, but that doesn't have USB access so not very informative. I also ran it on a native Windows machine. Windows Defender wasn't happy about it, but I didn't do any code signing. There it detected a connected device, so that's good.

I wonder if it makes sense for the deterministic binary releases to jump straight ahead to a more modern Python?

Also, would it make sense to do one final HWI release with Python 3.9 before merging this?

@Sjors
Copy link
Member Author

Sjors commented Jan 30, 2026

Added commit to re-enable the Ledger tests.

@Sjors Sjors force-pushed the 2026/01/python-bump branch from a4e3a84 to ae9e49d Compare January 31, 2026 09:04
@Sjors
Copy link
Member Author

Sjors commented Jan 31, 2026

Rebased just in case after recent merges.

@achow101
Copy link
Member

achow101 commented Feb 3, 2026

Does the dist build work on in an arm docker container, as described in the release process?

@Sjors Sjors force-pushed the 2026/01/python-bump branch from ae9e49d to f473a2e Compare February 3, 2026 11:20
@Sjors
Copy link
Member Author

Sjors commented Feb 3, 2026

Does the dist build work on in an arm docker container

I built inside an arm64 docker container on the x86 linux machine. I also made it do an hwi --help.

Rebased again, this time using generate_setup.py in the relevant commits, so e.g. the description field is updated when I touch the README.

The first time I ran that command, it moved hwilib.ui from packages to ui/* in package_data, see 35aa66a. No idea if that's correct.

I also built and tested the x86 macOS build on a native machine. I was able to run the QT application and it connected to a test deviced and fetch the descriptors.

Checksums:

19ee9fa6181421de1d6b404145438a1d00c61b3f0e55cc19a344f54fb5e76289  hwi-3.2.0-rc.1-linux-aarch64.tar.gz
3987142f1a441f893c28372b7ccd6a143b06c324cc9ee50f86b9cdb4d21f3204  hwi-3.2.0-rc.1-linux-aarch64.tar.gz/hwi
9909786e92a9cf0079d4aba986a6f8b856abba49c52a6df9e57dcae4c2e3c3a7  hwi-3.2.0-rc.1-linux-x86_64.tar.gz
64b5568167acd0d619f34c1739c430491b214bbf326bd8a4a2e0528c6b58d040  hwi-3.2.0-rc.1-linux-x86_64.tar.gz/hwi
97554105f474ba60b46d3b26534d254318114c05f5193c53e79bdf7167836239  hwi-3.2.0-rc.1-linux-x86_64.tar.gz/hwi-qt
83ac0f79ec5d9ecfb6aca98d325aaf05e47b3ba31b5c1e4fa69a2bfb088719d4  hwi-3.2.0-rc.1-mac-arm64.tar.gz
f9e884b02c2cd37e43f0668d32afef43cda649262d8ec891302a6d63f95026ed  hwi-3.2.0-rc.1-mac-arm64.tar.gz/hwi
6c070537a9f547c5b1e63a0c6d42aff9658a4e9305fa501c9e4ee752b04cdf3f  hwi-3.2.0-rc.1-mac-x86_64.tar.gz
241dea62a11ae2e18a547d8dd496e30cff7e005256ef460b6fde77aa303c6f40  hwi-3.2.0-rc.1-mac-x86_64.tar.gz/hwi
eea44149abb0a800c18f3895ea7b4f92937d01378bbfaa68ae74f89b4ef37aa3  hwi-3.2.0-rc.1-mac-x86_64.tar.gz/hwi-qt
be2d6ddb0fc18be6d9525c5004bc899e487e20ca51bd20aaa3e8e3ff43b28d0a  hwi-3.2.0-rc.1-windows-x86_64.zip
bf9e8a41e84537e1e3fa2310e8453a13cce50ee5befd8d6767e546bc29c17e2b  hwi-3.2.0-rc.1-windows-x86_64.zip/hwi-qt.exe
04b63d2a0b1e73253fe167aa7d9fe10e4da05f6c416319846b927deb00b000b1  hwi-3.2.0-rc.1-windows-x86_64.zip/hwi.exe
902438e1e1e988ab99099895f515ef701fc813fa42ad1620a733a6745f25933c  hwi-3.2.0rc1-py3-none-any.whl
f01ac678aa1c4da6e84eb83d42044a559acd0177313dd77b49a9494f9db9b7d6  hwi-3.2.0rc1.tar.gz

It's unused and occasionally trips up a test.
@Sjors
Copy link
Member Author

Sjors commented Feb 3, 2026

The spurious Ledger failure appears to be the result of the test suite occasionally hitting the Cancel / Reject button.

2026-02-03T12:43:44.9074661Z seproxyhal: received (tag: 0x60, size: 0x02): b'\x00\x00'
2026-02-03T12:43:44.9074759Z automation: getting actions for "" (0, 0)
2026-02-03T12:43:44.9074882Z automation: getting actions for "Reject" (46, 36)
2026-02-03T12:43:44.9075003Z seproxyhal: applying automation ['button', 1, True]
2026-02-03T12:43:44.9075128Z seproxyhal: applying automation ['button', 1, False]
2026-02-03T12:43:44.9075220Z seproxyhal.packet: send 05000100
...
2026-02-03T12:43:44.9077945Z apdu: < 6985

Where 0x6985: DenyError according to device_exception.py

Added a commit to drop that rule, since it's unused anyway.

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.

2 participants