piksel / pytouch-cube

Qt5 Label Editor for Brother P-Touch Cube label maker
MIT License
48 stars 9 forks source link

build(deps): pin first pybluez version that is compatible with modern SetupTools #36

Closed Mimoja closed 2 years ago

Mimoja commented 2 years ago

PyBluez is already aware of the issue that SetupTools no longer supports "use_2to3". https://github.com/pybluez/pybluez/issues/413 And fixed already in September 2021 in: https://github.com/pybluez/pybluez/commit/37d78880179b2a83e7052e0c2b9393499dd3b857 Sadly there is currently no new pypi release since 2019 so there is no tagged release for us to upgrade to. https://github.com/pybluez/pybluez/issues/416 This is due to the lack of a pybluez maintainer https://github.com/pybluez/pybluez/issues/411

To solve this we are pinning the commit that removed the use_2to3 in the requirements.txt allowing us to build with moden python distributions.

Testing done: Printed one Label with text and spacing

We are also only pulling in pybluez on linux as it wont work on windows and macos. Fixes: 20f11b082eeafc6367c0043c6c5dac8c27bc2a4b Transition to qt6 (#29)

Signed-off-by: Mimoja git@mimoja.de

piksel commented 2 years ago

I actually have a local fork of pybluez that also "works" on windows. It's crashy and usually doesn't list any devices, so I basically gave up on using it. The key feature was to be able to use rfcomm without mapping to tty devices (and requiring root). That's not really an issue on windows though.

@tyalie does this work correctly in your environment?

tyalie commented 2 years ago

The change works for me

piksel commented 2 years ago

Confirmed that this works using a fresh install of Ubuntu 22.04 with apt install libbluetooth-dev python3-pip.

Perhaps https://github.com/airgproducts/pybluez2 is a better alternative?