Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't get espanso running at all on Fedora / Wayland KDE Plasma #1955

Open
1 task
tigger04 opened this issue Apr 22, 2024 · 4 comments
Open
1 task

Can't get espanso running at all on Fedora / Wayland KDE Plasma #1955

tigger04 opened this issue Apr 22, 2024 · 4 comments
Labels
bug Something isn't working wayland

Comments

@tigger04
Copy link

Description

I feel like I've tried everything ... any help greatly appreciated!

Steps to reproduce

sudo dnf copr enable -y eclipseo/espanso
sudo dnf install -y espanso espanso-wayland

sudo setcap "cap_dac_override+p" $(which espanso-wayland)

espanso service unregister || :
espanso service register

... so far so good, then:

systemctl enable --user --now espanso-wayland
sudo systemctl enable --now espanso-wayland
espanso start --unmanaged

all yield errors, to the effect of e.g.

unable to start service: timed out
Hint: sometimes this happens because another Espanso process is left running for some reason.
      Please try running 'espanso restart' or manually killing all Espanso processes, then try again.

pkill/pgrep on espansoand espanso-wayland shows no process running

espanso restart yields:

espanso is not running!
unable to start service: timed out
Hint: sometimes this happens because another Espanso process is left running for some reason.
      Please try running 'espanso restart' or manually killing all Espanso processes, then try again.

espanso status yields:

espanso is not running

Expected behavior

Espanso running!

Screenshots

No response

Logs

No response

Your environment

  • Public source code:
  • Environment name and version (e.g., Rust 1.59.0):
  • Operating system and version (e.g., Ubuntu 20.04.2 LTS):
  • Espanso version (e.g., 2.1.4-beta):

Self-service

  • I'd be willing to fix this bug myself.
@tigger04 tigger04 added the bug Something isn't working label Apr 22, 2024
@tigger04
Copy link
Author

ok, facepalm moment.
espanso-wayland start --unmanaged
seems to have done it.
It would be good to get it working with systemd though - any tips on what I might be doing wrong?

@morgan-dgk
Copy link
Collaborator

Can you do espanso-wayland -vvvvv worker and share the log here? I assume this should work with the binary built for wayland as well.

@pointydev
Copy link

pointydev commented Apr 25, 2024

Similar issue, but using the espanso-wayland package from Terra:

[pointy@pointy ~]$ espanso -vvvvvv worker
19:12:19 [worker(10408)] [DEBUG] (1) espanso_path: detected config directory in $HOME/.config/espanso
19:12:19 [worker(10408)] [DEBUG] (1) espanso_path: detected default runtime dir: "/home/pointy/.cache/espanso"
19:12:19 [worker(10408)] [DEBUG] (1) espanso_path: detected default packages dir: "/home/pointy/.config/espanso/match/packages"
19:12:19 [worker(10408)] [INFO] reading configs from: "/home/pointy/.config/espanso"
19:12:19 [worker(10408)] [INFO] reading packages from: "/home/pointy/.config/espanso/match/packages"
19:12:19 [worker(10408)] [INFO] using runtime dir: "/home/pointy/.cache/espanso"
19:12:19 [worker(10408)] [INFO] system info: Fedora Linux v40 - kernel: 6.8.7-300.fc40.x86_64
19:12:19 [worker(10408)] [DEBUG] (1) espanso_config::config::store: loaded default config at path: "/home/pointy/.config/espanso/config/default.yml"
19:12:19 [worker(10408)] [DEBUG] (1) espanso_config::config::store: loaded config at path: "/home/pointy/.config/espanso/config/csgo.yml"
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'alacritty_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'emacs_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'gedit_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'generic_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'kitty_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'konsole_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'libreoffice_writer_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'simple_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'simple_terminal_2_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'terminator_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'termite_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'thunderbird_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'tilix_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'urxvt_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'xterm_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'yakuake_terminal_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::patch::config_store: skipping 'virtualbox_x11' patch
19:12:19 [worker(10408)] [DEBUG] (1) espanso::cli::worker: starting with start-reason = None
19:12:19 [worker(10408)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/iconv2.png"', as it's already present
19:12:19 [worker(10408)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/search.png"', as it's already present
19:12:19 [worker(10408)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/icon_no_background.png"', as it's already present
19:12:19 [worker(10408)] [INFO] using WaylandAppInfoProvider
19:12:19 [worker(10408)] [INFO] binded to IPC unix socket: /home/pointy/.cache/espanso/espansoworkerv2.sock
19:12:19 [worker(10408)] [WARN] this version of espanso doesn't come with modulo support, so graphical features (such as Forms and Search) might not be available
19:12:19 [worker(10408)] [WARN] EVDEV backend is being used, but without enabling linux capabilities.
19:12:19 [worker(10408)] [WARN]   Although you CAN run espanso EVDEV backend as root, it's not recommended due
19:12:19 [worker(10408)] [WARN]   to security reasons. Espanso supports linux capabilities to limit the attack surface
19:12:19 [worker(10408)] [WARN]   area by only leveraging on the CAP_DAC_OVERRIDE capability (needed to work with
19:12:19 [worker(10408)] [WARN]   /dev/input/* devices to detect and inject text) and disabling it as soon as the
19:12:19 [worker(10408)] [WARN]   initial setup is completed.
19:12:19 [worker(10408)] [WARN] unable to determine keyboard layout automatically, please explicitly specify it in the configuration.
19:12:19 [worker(10408)] [INFO] using EVDEVSource
19:12:19 [worker(10408)] [ERROR] Unable to open EVDEV devices, this usually has to do with permissions.
19:12:19 [worker(10408)] [ERROR] You can either add the current user to the 'input' group or run espanso as root
19:12:19 [worker(10408)] [ERROR] thread 'engine thread' panicked at 'failed to initialize detector module: detection source initialization failed': espanso/src/cli/worker/engine/mod.rs:140
19:12:19 [worker(10408)] [ERROR] Unable to block the LinuxEventLoop: receiving on an empty and disconnected channel
19:12:19 [worker(10408)] [ERROR] thread 'main' panicked at 'unable to run main eventloop: receiving on an empty and disconnected channel': espanso/src/cli/worker/mod.rs:160

Tried adding myself to the input group as suggested, but to no avail. Notably, I cannot start using espanso start --unmanaged either.

@pointydev
Copy link

After running sudo setcap "cap_dac_override+p" $(which espanso), while I still can't run espanso start --unmanaged, I get this log for the worker:

[pointy@pointy ~]$ espanso -vvvvvv worker
19:32:46 [worker(12873)] [DEBUG] (1) espanso_path: detected config directory in $HOME/.config/espanso
19:32:46 [worker(12873)] [DEBUG] (1) espanso_path: detected default runtime dir: "/home/pointy/.cache/espanso"
19:32:46 [worker(12873)] [DEBUG] (1) espanso_path: detected default packages dir: "/home/pointy/.config/espanso/match/packages"
19:32:46 [worker(12873)] [INFO] reading configs from: "/home/pointy/.config/espanso"
19:32:46 [worker(12873)] [INFO] reading packages from: "/home/pointy/.config/espanso/match/packages"
19:32:46 [worker(12873)] [INFO] using runtime dir: "/home/pointy/.cache/espanso"
19:32:46 [worker(12873)] [INFO] system info: Fedora Linux v40 - kernel: 6.8.7-300.fc40.x86_64
19:32:46 [worker(12873)] [DEBUG] (1) espanso_config::config::store: loaded default config at path: "/home/pointy/.config/espanso/config/default.yml"
19:32:46 [worker(12873)] [DEBUG] (1) espanso_config::config::store: loaded config at path: "/home/pointy/.config/espanso/config/csgo.yml"
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'alacritty_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'emacs_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'gedit_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'generic_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'kitty_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'konsole_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'libreoffice_writer_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'simple_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'simple_terminal_2_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'terminator_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'termite_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'thunderbird_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'tilix_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'urxvt_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'xterm_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'yakuake_terminal_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::patch::config_store: skipping 'virtualbox_x11' patch
19:32:46 [worker(12873)] [DEBUG] (1) espanso::cli::worker: starting with start-reason = None
19:32:46 [worker(12873)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/iconv2.png"', as it's already present
19:32:46 [worker(12873)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/search.png"', as it's already present
19:32:46 [worker(12873)] [DEBUG] (1) espanso::icon: skipping extraction for '"/home/pointy/.cache/espanso/icon_no_background.png"', as it's already present
19:32:46 [worker(12873)] [INFO] using WaylandAppInfoProvider
19:32:46 [worker(12873)] [INFO] binded to IPC unix socket: /home/pointy/.cache/espanso/espansoworkerv2.sock
19:32:46 [worker(12873)] [WARN] this version of espanso doesn't come with modulo support, so graphical features (such as Forms and Search) might not be available
19:32:46 [worker(12873)] [DEBUG] (2) espanso::cli::worker::engine: using linux capabilities to grant permissions needed by EVDEV backend
19:32:46 [worker(12873)] [DEBUG] (2) espanso::cli::worker::engine: successfully granted permissions using capabilities
19:32:46 [worker(12873)] [WARN] unable to determine keyboard layout automatically, please explicitly specify it in the configuration.
19:32:46 [worker(12873)] [INFO] using EVDEVSource
19:32:46 [worker(12873)] [INFO] Querying modifier status...
19:32:46 [worker(12873)] [DEBUG] (4) espanso_detect::evdev: Updating device modifier state: ModifiersState { ctrl: false, alt: false, shift: false, caps_lock: false, meta: false, num_lock: false }
19:32:46 [worker(12873)] [WARN] unable to determine keyboard layout automatically, please explicitly specify it in the configuration.
19:32:46 [worker(12873)] [INFO] using EVDEVInjector
19:32:46 [worker(12873)] [INFO] using WaylandFallbackClipboard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working wayland
Projects
None yet
Development

No branches or pull requests

3 participants