Bug 457932

Summary: Shortcuts for opening WezTerm no longer work
Product: [Frameworks and Libraries] frameworks-kglobalaccel Reporter: poperigby
Component: generalAssignee: kdelibs bugs <kdelibs-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: nate
Priority: NOR    
Version: 5.97.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: kglobalshortcutsrc

Description poperigby 2022-08-15 20:01:23 UTC
SUMMARY
I'm not sure if it was after an update, but my Meta+Return shortcut for launching WezTerm (https://wezfurlong.org/wezterm/) no longer works. I also tried binding different shortcuts to it, but none work. Open WezTerm via KRunner does work though.

STEPS TO REPRODUCE
1. Go to Settings -> Shortcuts -> Add application -> WezTerm, and bind a key combination to it.
2. Try pressing that key combination.

OBSERVED RESULT
WezTerm doesn't launch.

EXPECTED RESULT
WezTerm launches.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.25.4
KDE Frameworks Version: 5.97.0
Qt Version: 5.15.5
Kernel Version: 5.19.1-arch2-1 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 3700X 8-Core Processor
Memory: 15.5 GiB of RAM
Graphics Processor: AMD Radeon RX 5700 XT
Manufacturer: ASUS
Comment 1 Nate Graham 2022-08-15 20:47:43 UTC
Can you attach your ~/.config/kglobalshortcutsrc file?
Comment 2 poperigby 2022-08-15 20:48:29 UTC
(In reply to Nate Graham from comment #1)
> Can you attach your ~/.config/kglobalshortcutsrc file?

Sure!
Comment 3 poperigby 2022-08-15 20:49:11 UTC
Created attachment 151346 [details]
kglobalshortcutsrc
Comment 4 Nate Graham 2022-08-15 20:57:43 UTC
> [org.wezfurlong.wezterm.desktop]
> _k_friendly_name=WezTerm
> _launch=Meta+Return,none,WezTerm

Ok, so KGlobalAccel has registered the shortcut. A few more questions:
1. Does this shortcut work if you set it as the launch shortcut for any other app?
2. How was WezTerm installed? Distro packaging? Flatpak? Snap? Appimage?
3. Does WezTerm launch if you set any other shortcut for it?
Comment 5 Nate Graham 2022-08-15 20:59:36 UTC
Oh one final question: can you paste the output of `appstreamcli search wezterm` on your machine?
Comment 6 poperigby 2022-08-15 21:01:21 UTC
(In reply to Nate Graham from comment #4)

> Does this shortcut work if you set it as the launch shortcut for any other app?

Yes. I tried setting Meta+Return to open Konsole and that worked.

> How was WezTerm installed? Distro packaging? Flatpak? Snap? Appimage?

I installed it from the Arch Linux repository.

> Does WezTerm launch if you set any other shortcut for it?

No. I've tried Meta+T, Ctrl+Alt+T, Ctrl+Shift+T, etc.

> Oh one final question: can you paste the output of `appstreamcli search
wezterm` on your machine?

Here you go:
Identifier: org.wezfurlong.wezterm.desktop [desktop-application]
Name: Wez's Terminal Emulator
Summary: A GPU-accelerated cross-platform terminal emulator and multiplexer
Package: wezterm
Homepage: https://wezfurlong.org/wezterm/
Icon: wezterm_org.wezfurlong.wezterm.png
---
Identifier: org.wezfurlong.wezterm [desktop-application]
Name: Wez's Terminal Emulator
Summary: A GPU-accelerated cross-platform terminal emulator and multiplexer
Bundle: flatpak:app/org.wezfurlong.wezterm/x86_64/stable
Homepage: https://wezfurlong.org/wezterm/
Icon: org.wezfurlong.wezterm.png
Comment 7 Nate Graham 2022-08-15 21:03:43 UTC
Great, thanks. Does /usr/share/applications/org.wezfurlong.wezterm.desktop exist?
Comment 8 poperigby 2022-08-15 21:05:26 UTC
(In reply to Nate Graham from comment #7)
> Great, thanks. Does /usr/share/applications/org.wezfurlong.wezterm.desktop
> exist?

You're welcome. Yeah, it does. Here's its contents:

[Desktop Entry]
Name=WezTerm
Comment=Wez's Terminal Emulator
Keywords=shell;prompt;command;commandline;cmd;
Icon=org.wezfurlong.wezterm
StartupWMClass=org.wezfurlong.wezterm
TryExec=wezterm
Exec=wezterm start --cwd . --
Type=Application
Categories=System;TerminalEmulator;Utility;
Terminal=false
Comment 9 Bug Janitor Service 2022-08-15 21:38:33 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kglobalaccel/-/merge_requests/50
Comment 10 Nate Graham 2022-08-15 23:48:20 UTC

*** This bug has been marked as a duplicate of bug 440507 ***