input-remapper-gtk won't launch
I can't launch the input-remapper-gtk GUI. i tried launching it through the terminal this error pops up
OS: Artix Linux x86_64
Kernel: Linux 6.15.8-artix1-1
Traceback (most recent call last): File "/usr/bin/input-remapper-gtk", line 26, in
InputRemapperGtkBin.main() ~~~~~~~~~~~~~~~~~~~~~~~~^^ File "/usr/lib/python3.13/site-packages/inputremapper/bin/input_remapper_gtk.py", line 94, in main reader_client = ReaderClient(message_broker, _Groups()) File "/usr/lib/python3.13/site-packages/inputremapper/gui/reader_client.py", line 79, in init self._results_pipe, self._commands_pipe = self.connect() ~~~~~~~~~~~~^^ File "/usr/lib/python3.13/site-packages/inputremapper/gui/reader_client.py", line 122, in connect results_pipe = Pipe(ReaderService.get_pipe_paths()[0]) File "/usr/lib/python3.13/site-packages/inputremapper/ipc/pipe.py", line 67, in init PathUtils.mkdir(os.path.dirname(path)) ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 86, in mkdir PathUtils.mkdir(base, log=False) ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 89, in mkdir PathUtils.chown(path) ~~~~~~~~~~~~~~~^^^^^^ File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 49, in chown shutil.chown(path, user=UserUtils.user, group=UserUtils.user) ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.13/shutil.py", line 1436, in chown os.chown(path, _user, _group, dir_fd=dir_fd, ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ follow_symlinks=follow_symlinks) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ PermissionError: [Errno 1] Operation not permitted: '/tmp/input-remapper-/home' Exception ignored in: <function Pipe.del at 0x7f8cc244b4c0> Traceback (most recent call last): File "/usr/lib/python3.13/site-packages/inputremapper/ipc/pipe.py", line 108, in del for file in self._handles: AttributeError: 'Pipe' object has no attribute '_handles
I'm seeing the same thing on Fedora 42, Python 3.13.9 with input-remapper 2.1.1. It has worked for me before, but I'm not sure when it started failing as I have been using X11 instead of Wayland again for a few months, but am migrating back to Wayland in advance of Fedora 43 removing GNOME X11. Hmm, that said, I had thought I was using this under the X11 session as well, so it may have been a very recent update.
Just in case, my most recent update a couple of days ago included these python packages (not input-remapper), but I don't think it's relevant:
Upgrade python3-audit-0:4.1.2-2.fc42.x86_64 User updates
Upgrade python3-boto3-0:1.40.61-1.fc42.noarch Weak Dependency updates
Upgrade python3-botocore-0:1.40.61-1.fc42.noarch Dependency updates
Upgrade python3-perf-0:6.17.5-200.fc42.x86_64 External User updates
Upgrade python3-sssdconfig-0:2.11.1-2.fc42.noarch Dependency updates
Upgrade python3-unbound-0:1.24.1-1.fc42.x86_64 User updates
Other reports don't have quite the same output (here, a seemingly mangled path with no username). I can't quite make out what it's trying to do, the dir in question seems to be created by the GUI not the service, and so is already owned by the user. I'll be (trying to!) edit my local username to username in the debug.
Here's my run:
> input-remapper-gtk -d
10:22:12.638248 13421 GUI INFO logger.py:107: input-remapper-gtk 2.1.1 https://github.com/sezanzeb/input-remapper
10:22:12.638330 13421 GUI INFO logger.py:115: python-evdev 1.9.1
10:22:12.638369 13421 GUI WARNING logger.py:118: Debug level will log all your keystrokes! Do not post this output in the internet if you typed in sensitive or private information with your device!
10:22:12.638401 13421 GUI DEBUG input_remapper_gtk.py:80: Using locale directory: /usr/share/input-remapper/lang
10:22:12.638562 13421 GUI INFO paths.py:81: Creating dir "/tmp/input-remapper-/home/username"
10:22:12.638641 13421 GUI DEBUG paths.py:48: Chown "/tmp/input-remapper-/home", "username"
Traceback (most recent call last):
File "/usr/bin/input-remapper-gtk", line 26, in <module>
InputRemapperGtkBin.main()
~~~~~~~~~~~~~~~~~~~~~~~~^^
File "/usr/lib/python3.13/site-packages/inputremapper/bin/input_remapper_gtk.py", line 94, in main
reader_client = ReaderClient(message_broker, _Groups())
File "/usr/lib/python3.13/site-packages/inputremapper/gui/reader_client.py", line 79, in __init__
self._results_pipe, self._commands_pipe = self.connect()
~~~~~~~~~~~~^^
File "/usr/lib/python3.13/site-packages/inputremapper/gui/reader_client.py", line 122, in connect
results_pipe = Pipe(ReaderService.get_pipe_paths()[0])
File "/usr/lib/python3.13/site-packages/inputremapper/ipc/pipe.py", line 67, in __init__
PathUtils.mkdir(os.path.dirname(path))
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 86, in mkdir
PathUtils.mkdir(base, log=False)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 89, in mkdir
PathUtils.chown(path)
~~~~~~~~~~~~~~~^^^^^^
File "/usr/lib/python3.13/site-packages/inputremapper/configs/paths.py", line 49, in chown
shutil.chown(path, user=UserUtils.user, group=UserUtils.user)
~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.13/shutil.py", line 1436, in chown
os.chown(path, _user, _group, dir_fd=dir_fd,
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
follow_symlinks=follow_symlinks)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
PermissionError: [Errno 1] Operation not permitted: '/tmp/input-remapper-/home'
Exception ignored in: <function Pipe.__del__ at 0x7f2915dba5c0>
Traceback (most recent call last):
File "/usr/lib/python3.13/site-packages/inputremapper/ipc/pipe.py", line 108, in __del__
for file in self._handles:
AttributeError: 'Pipe' object has no attribute '_handles'
> ls -lR /tmp/input-remapper-/
'/tmp/input-remapper-/':
total 0
drwxr-xr-x 2 username groupname 40 Nov 4 10:22 'home'/
'/tmp/input-remapper-/home':
total 0
Hmm, OK, so the GUI also does not work for my if I switch back to X11 GNOME, this is unsurprising. However, I do now think that input-remapper is no longer working for me so it's likely been broken for me for a while (I think I'm actually still using xbindkeys for the maps I want there), maybe the devices are not matching any more? That's a job for another day, though.
So the main issue is not being able to launch the GUI and maybe recreate my config. I may look into doing it manually at some point to see if it is even still working at remapping for me.
I managed to kludge past the issue and get the GUI up with:
--- /usr/lib/python3.13/site-packages/inputremapper/configs/paths.py.orig 2025-03-06 00:00:00.000000000 +0000
+++ /usr/lib/python3.13/site-packages/inputremapper/configs/paths.py 2025-11-04 11:21:18.110705536 +0000
@@ -50,6 +50,9 @@
except LookupError:
# the users group was unknown in one case for whatever reason
shutil.chown(path, user=UserUtils.user)
+ except PermissionError:
+ # whoops
+ logger.info('Exception doing chown')
@staticmethod
def touch(path: Union[str, os.PathLike], log=True):
.. but there's still something not quite right. As expected, the devices are manifesting differently from before so my config is not being picked up. But even changing it (well, I copied my old device json to the new ID's one) while it shows up in the [requires root] GUI, and 'playing' it works, it does not update my main config.json nor does it apply those settings automatically when I log in. I did have to manually update my main config.json to refer to the new device ID, ther GUI didn't seem to want to? I may try again at some point from a complete blank slate.
Did my config from scratch, and also created a dummy, empty, config.json under ~root as the logs were repeatedly reporting an error from the service about it not being there, and now my settings do work from login automatically.
Not sure which step was ultimately needed, but looking at the deltas it is likely due to confusion on my part from the device rename. I have a preset from the GUI called “Logitech Wireless Device PID_4041 Mouse” (used to be “Logitech MX Master”), however the actual device name needed for config.json, as reported by input-remapper-control --list-devices is “Logitech Wireless Device PID:4041 Mouse”.
If the nuance is in the readme between the folder having an underscore where the device name has a colon, I must have missed it! (I have not tried having the colon also in the reset directory name, but left it as the GUI created it).
Anyway, that's enough noise from me, it just leaves the oddity with the GUI crashing.