rbreaves / kinto

Mac-style shortcut keys for Linux & Windows.
http://kinto.sh
GNU General Public License v2.0
4.24k stars 212 forks source link

Default Task Switcher not working correctly on Manjaro KDE Plasma #833

Open franciscosili opened 9 months ago

franciscosili commented 9 months ago

Describe the bug I have installed Kinto.sh and now the task switcher does not work correctly. By default, when I type Cmd+Tab it is mapped to Alt+Tab. It does work but changing one app at the time and I don't get the Visualisation of it (in my case being Large Icons), even if I keep Cmd pressed.

I might be thinking this is because once the command is executed, it does not recognise that the key is kept pressed.

On the other hand, when I go in the reverse order, that is, I press Cmd+Shft+Tab the visualisation appears correctly.

Expected behavior Visualisation of the Task Switcher when using the default TaskSwitcher command.

Install Type: Bare Metal Distro: Manjaro 6.5.3-1 DE: KDE 5.27.8

Logs and status if relevant

# xkeysnail
$ sudo systemctl status xkeysnail                                                                                                                                                                            
● xkeysnail.service - xkeysnail
     Loaded: loaded (/usr/lib/systemd/system/xkeysnail.service; bad; preset: disabled)
     Active: active (running) since Wed 2023-09-27 11:57:19 -03; 1h 4min ago
   Main PID: 1384 (sudo)
      Tasks: 2 (limit: 18978)
     Memory: 18.9M
        CPU: 5.382s
     CGroup: /system.slice/xkeysnail.service
             ├─1384 /usr/bin/sudo /bin/bash -c "/usr/bin/xhost +SI:localuser:root && /home/fsili/.config/kinto/killdups.sh && /usr/bin/xkeysnail --quiet --watch /home/fsili/.config/kinto/kinto.py"
             └─1386 /usr/bin/python /usr/bin/xkeysnail --quiet --watch /home/fsili/.config/kinto/kinto.py

sep 27 11:57:19 fsili-iflp systemd[1]: xkeysnail.service: Scheduled restart job, restart counter is at 4.
sep 27 11:57:19 fsili-iflp systemd[1]: Started xkeysnail.
sep 27 11:57:19 fsili-iflp sudo[1384]:     root : PWD=/ ; USER=root ; COMMAND=/bin/bash -c '/usr/bin/xhost +SI:localuser:root && /home/fsili/.config/kinto/killdups.sh && /usr/bin/xkeysnail --quiet --watch /home/fsili/.config/kinto/kinto.py'
sep 27 11:57:19 fsili-iflp sudo[1384]: pam_unix(sudo:session): session opened for user root(uid=0) by (uid=0)
sep 27 11:57:19 fsili-iflp sudo[1387]: localuser:root being added to access control list

===========================================================================================================================

$ sudo journalctl --unit=xkeysnail.service -b
sep 27 11:57:02 fsili-iflp systemd[1]: Started xkeysnail.
sep 27 11:57:02 fsili-iflp sudo[1031]:     root : PWD=/ ; USER=root ; COMMAND=/bin/bash -c '/usr/bin/xhost +SI:localuser:root && /home/fsili/.config/kinto/killdups.sh && /usr/bin/xkeysnail --quiet --watch /home/fsili/.config/kinto/kinto.py'
sep 27 11:57:02 fsili-iflp sudo[1031]: pam_unix(sudo:session): session opened for user root(uid=0) by (uid=0)
sep 27 11:57:02 fsili-iflp sudo[1038]: localuser:root being added to access control list
sep 27 11:57:03 fsili-iflp sudo[1035]: ██╗  ██╗██╗  ██╗███████╗██╗   ██╗
sep 27 11:57:03 fsili-iflp sudo[1035]: ╚██╗██╔╝██║ ██╔╝██╔════╝╚██╗ ██╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]:  ╚███╔╝ █████╔╝ █████╗   ╚████╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]:  ██╔██╗ ██╔═██╗ ██╔══╝    ╚██╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]: ██╔╝ ██╗██║  ██╗███████╗   ██║
sep 27 11:57:03 fsili-iflp sudo[1035]: ╚═╝  ╚═╝╚═╝  ╚═╝╚══════╝   ╚═╝
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████╗███╗   ██╗ █████╗ ██╗██╗
sep 27 11:57:03 fsili-iflp sudo[1035]:   ██╔════╝████╗  ██║██╔══██╗██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████╗██╔██╗ ██║███████║██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ╚════██║██║╚██╗██║██╔══██║██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████║██║ ╚████║██║  ██║██║███████╗
sep 27 11:57:03 fsili-iflp sudo[1035]:   ╚══════╝╚═╝  ╚═══╝╚═╝  ╚═╝╚═╝╚══════╝
sep 27 11:57:03 fsili-iflp sudo[1035]:                              v0.4.0
sep 27 11:57:03 fsili-iflp sudo[1035]: No keyboard devices specified via (--devices) option.
sep 27 11:57:03 fsili-iflp sudo[1035]: xkeysnail picks up keyboard-ish devices from the list below:
sep 27 11:57:03 fsili-iflp sudo[1035]: ------------------------------------------------------------------------------------
sep 27 11:57:03 fsili-iflp sudo[1035]: Device               Name                                Phys
sep 27 11:57:03 fsili-iflp sudo[1035]: ------------------------------------------------------------------------------------
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event0    Sleep Button                        PNP0C0E/button/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event1    Power Button                        PNP0C0C/button/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event2    Power Button                        LNXPWRBN/button/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event3    PC Speaker                          isa0061/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event4    Eee PC WMI hotkeys                  eeepc-wmi/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event5    Video Bus                           LNXVIDEO/video/input0
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event6    HDA Intel PCH Front Mic             ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event7    HDA Intel PCH Rear Mic              ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event8    HDA Intel PCH Line                  ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event9    HDA Intel PCH Line Out              ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event10   HDA Intel PCH Front Headphone       ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event11   HDA Intel PCH HDMI/DP,pcm=3         ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event12   HDA Intel PCH HDMI/DP,pcm=7         ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event13   HDA Intel PCH HDMI/DP,pcm=8         ALSA
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event14   Logitech MX Anywhere 3              usb-0000:00:14.0-1/input2:1
sep 27 11:57:03 fsili-iflp sudo[1035]: /dev/input/event15   py-evdev-uinput                     py-evdev-uinput
sep 27 11:57:03 fsili-iflp sudo[1035]: error: no input devices found (do you have rw permission on /dev/input/*?)
sep 27 11:57:03 fsili-iflp sudo[1031]: pam_unix(sudo:session): session closed for user root
sep 27 11:57:03 fsili-iflp systemd[1]: xkeysnail.service: Main process exited, code=exited, status=1/FAILURE
sep 27 11:57:03 fsili-iflp systemd[1]: xkeysnail.service: Failed with result 'exit-code'.
sep 27 11:57:06 fsili-iflp systemd[1]: xkeysnail.service: Scheduled restart job, restart counter is at 1.

# xkb
$ systemctl --user status keyswap
Unit keyswap.service could not be found.

$ journalctl --user-unit=keyswap.service -b
-- No entries --

What I can see from the logs posted above, there is a case something fails. I do not understand everything fully, since I'm quite a beginner: I just connected my Magic Keyboard to a new Manjaro install and expected everything to work.

I have tried previously, some months ago, probably on an older Manjaro version, and everything worked fine out-of-the-box.

Thank you very much for your help. Cheers, Fran

RedBearAK commented 9 months ago

@franciscosili

You bypassed the Python “managed environment” problem during the Kinto install by using pip or pipx to install xkeysnail separately, which installed v0.4.0 instead of the v0.3.0 branch that the Kinto installer clones in its own folder in Downloads.

sep 27 11:57:03 fsili-iflp sudo[1035]: ██╗  ██╗██╗  ██╗███████╗██╗   ██╗
sep 27 11:57:03 fsili-iflp sudo[1035]: ╚██╗██╔╝██║ ██╔╝██╔════╝╚██╗ ██╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]:  ╚███╔╝ █████╔╝ █████╗   ╚████╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]:  ██╔██╗ ██╔═██╗ ██╔══╝    ╚██╔╝
sep 27 11:57:03 fsili-iflp sudo[1035]: ██╔╝ ██╗██║  ██╗███████╗   ██║
sep 27 11:57:03 fsili-iflp sudo[1035]: ╚═╝  ╚═╝╚═╝  ╚═╝╚══════╝   ╚═╝
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████╗███╗   ██╗ █████╗ ██╗██╗
sep 27 11:57:03 fsili-iflp sudo[1035]:   ██╔════╝████╗  ██║██╔══██╗██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████╗██╔██╗ ██║███████║██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ╚════██║██║╚██╗██║██╔══██║██║██║
sep 27 11:57:03 fsili-iflp sudo[1035]:   ███████║██║ ╚████║██║  ██║██║███████╗
sep 27 11:57:03 fsili-iflp sudo[1035]:   ╚══════╝╚═╝  ╚═══╝╚═╝  ╚═╝╚═╝╚══════╝
sep 27 11:57:03 fsili-iflp sudo[1035]:                              v0.4.0

Go into the Downloads/kinto-master/xkeysnail folder and install from that folder with pipx.

sudo pipx install --upgrade .

That should overwrite the system-level xkeysnail install with the correct version that doesn’t have this problem. Then restart Kinto to start using it.

franciscosili commented 9 months ago

Hi @RedBearAK Thanks a lot for the response. Indeed it was that.

However doing that didn't work at first but needed to add the flag --break-system-packages to that command, and run the install.sh script again.

I tried it with a fresh isntall on Kubuntu and Manjaro KDE, both cases needed that flag.

The whole sequence of commands was then:

$ /bin/bash -c "$(wget -qO- https://raw.githubusercontent.com/rbreaves/kinto/HEAD/install/linux.sh || curl -fsSL https://raw.githubusercontent.com/rbreaves/kinto/HEAD/install/linux.sh)

If it fails do the following:

$ cd ~/Downloads/kinto-master/xkeysnail
$ sudo pip3 install --upgrade --break-system-packages .
$ cd ~/Downloads/kinto-master
$ source install/linux.sh

and finally everything worked well.

Thanks a lot!

RedBearAK commented 9 months ago

needed to add the flag --break-system-packages

@franciscosili

The point of using “pipx” instead of “pip” or “pip3” is to avoid needing that flag. It is a different program.