diff --git a/lib/hidapi/udev.py b/lib/hidapi/udev.py index e25ab2f5..a4cbfcf0 100644 --- a/lib/hidapi/udev.py +++ b/lib/hidapi/udev.py @@ -38,7 +38,6 @@ from time import time as _timestamp import gi -from hid_parser import ReportDescriptor as _ReportDescriptor from pyudev import Context as _Context from pyudev import Device as _Device from pyudev import DeviceNotFoundError @@ -115,6 +114,8 @@ def _match(action, device, filterfn): return # these are devices connected through a receiver so don't pick them up here try: # if report descriptor does not indicate HID++ capabilities then this device is not of interest to Solaar + from hid_parser import ReportDescriptor as _ReportDescriptor + hidpp_short = hidpp_long = False devfile = "/sys" + hid_device.get("DEVPATH") + "/report_descriptor" with fileopen(devfile, "rb") as fd: diff --git a/setup.py b/setup.py index 9b40ddce..7502b871 100755 --- a/setup.py +++ b/setup.py @@ -76,6 +76,7 @@ For instructions on installing Solaar see https://pwr-solaar.github.io/Solaar/in python_requires=">=3.7", install_requires=[ 'evdev (>= 1.1.2) ; platform_system=="Linux"', + 'hid_parser (>= 0.0.3) ; platform_system=="Linux"', "pyudev (>= 0.13)", "PyYAML (>= 3.12)", "python-xlib (>= 0.27)",