flyte / mqtt-io

Expose GPIO modules (Raspberry Pi, Beaglebone, PCF8754, PiFace2 etc.) and digital sensors (LM75 etc.) to an MQTT server for remote control and monitoring.
MIT License
460 stars 157 forks source link

adxl345 Module outdated and does not install #362

Open mschlenstedt opened 3 months ago

mschlenstedt commented 3 months ago

Unfortunately the recently added adxl345 module could not be installed anymore. As far as I could figure out "use_2to3" was removed in sezuptools > 58.0:

root@loxberry:~# python3 -m pip install --upgrade adxl345
Collecting adxl345
  Downloading adxl345-1.0.4.tar.gz (3.1 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [1 lines of output]
      error in adxl345 setup command: use_2to3 is invalid.
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

The Git Repo of adxl345 says that the code is outdated and better use https://github.com/adafruit/Adafruit_Python_ADXL345 (see here: https://github.com/pimoroni/adxl345-python).

Unfortunately I have no adxl345 here and therefore could not rewrite the sensor module...

mschlenstedt commented 3 months ago

Workaround is to temporarly install setuptools <58.0:

pip3 install "setuptools<58.0.0" wheel
pip3 install adxl345
pip3 install setuptools wheel