Closed Apacelus closed 2 years ago
Thank you for your report.
PYNPUT_BACKEND_KEYBOARD=uinput
will override the backend for the keyboard module, but the mouse module will still use the default modules, and the checks for both are always run when importing pynput
.
Use PYNPUT_BACKEND_MOUSE=dummy
to force the dummy backend for mouse.
Your code snippet also looks a bit strange; if you run your script with sudo
, please ensure that the environment variables are actually passed: sudo env PYSTRAY_BACKEND_KEYBOARD=uinput PYSTRAY_BACKEND_MOUSE=dummy python3 logger.py
.
I am really sorry I have to ask this, but how do I force the script to use uinput? I am trying to run the script on a headless machine with no xserver.
When I enter this command:
sudo python3 logger.py $PYNPUT_BACKEND_KEYBOARD=uinput
I get the same error as when running without root privileges and the environment variable:What am I doing wrong?