IRNAS / irnas-zephyr-template

Template for Zephyr Projects
3 stars 1 forks source link

BUG - Pre-commit: Can't use beautysh tool with python 3.12 on MacOS #26

Closed vid553 closed 2 months ago

vid553 commented 2 months ago

Describe the bug

I am unable to use the Beautysh hook as part of a pre-commit tool as it throws an error. The error appears to be related to setuptools and the newest python versions.

Error print:

beautysh.................................................................Failed
- hook id: beautysh
- exit code: 1

Traceback (most recent call last):
  File "/Users/vid/.cache/pre-commit/repow2fet6qs/py_env-python3.12/bin/beautysh", line 5, in <module>
    from beautysh import main
  File "/Users/vid/.cache/pre-commit/repow2fet6qs/py_env-python3.12/lib/python3.12/site-packages/beautysh/__init__.py", line 9, in <module>
    import pkg_resources  # part of setuptools
    ^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'pkg_resources'

Firmware/software version

Additional context