diff --git a/keymapper/dev/injector.py b/keymapper/dev/injector.py index 264599ec..861f7e91 100644 --- a/keymapper/dev/injector.py +++ b/keymapper/dev/injector.py @@ -75,7 +75,7 @@ def is_numlock_on(): return num_lock_status[1] == 'on' return False - except subprocess.CalledProcessError: + except (FileNotFoundError, subprocess.CalledProcessError): # tty return None @@ -435,6 +435,11 @@ class Injector: if len(macros) == 0: logger.debug('No macros configured') + logger.spam( + 'Original capabilities for "%s": %s', + path, source.capabilities(verbose=True) + ) + # certain capabilities can have side effects apparently. with an # EV_ABS capability, EV_REL won't move the mouse pointer anymore. # so don't merge all InputDevices into one UInput device. diff --git a/tests/test.py b/tests/test.py index 3a798ab7..6a487844 100644 --- a/tests/test.py +++ b/tests/test.py @@ -306,7 +306,7 @@ class InputDevice: yield result await asyncio.sleep(0.01) - def capabilities(self, absinfo=True): + def capabilities(self, absinfo=True, verbose=False): result = copy.deepcopy(fixtures[self.path]['capabilities']) if absinfo and evdev.ecodes.EV_ABS in result: