Hello,
I installed Fcitx5 on my NixOS, but it doesn’t auto-launch with my desktop.
Here is my opinion on what goes wrong: There are 3 relevant systemd service: app-org.fcitx.Fcitx5@autostart.service
(seems like auto-generated from an XDG autostart file managed by home-manager) and fcitx5-daemon.service
generated by home-manager i18n configuration for Fcitx5, and niri.service
for my WM. When I log in to my desktop, these happen:
app-org.fcitx.Fcitx5@autostart.service
auto-started before my WM, and hanged after failing to open Wayland connection instead of exiting and occupied DBus name.- My WM started to listen on Wayland socket, and started
fcitx5-daemon.service
, which is intended. fcitx5-daemon.service
failed due to a failing request for the DBus name occupied byapp-org.fcitx.Fcitx5@autostart.service
before.
My system version:
- Nixpkgs
9cdd04
; - home-manager
080e8b
; - niri 25.05.1;
- Fcitx5 5.1.12.
journalctl
output:
$ journalctl --user -u app-org.fcitx.Fcitx5@autostart.service --no-pager
6月 29 12:53:22 desktop systemd[1404]: Starting Fcitx 5...
6月 29 12:53:22 desktop systemd[1404]: Started Fcitx 5.
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.397746 instance.cpp:1394] Override Enabled Addons: {}
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.397803 instance.cpp:1395] Override Disabled Addons: {}
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.399967 addonmanager.cpp:205] Loaded addon imselector
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.401949 addonmanager.cpp:205] Loaded addon quickphrase
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.403846 addonmanager.cpp:205] Loaded addon xcb
6月 29 12:53:22 desktop fcitx5[1460]: E2025-06-29 12:53:22.406049 waylandmodule.cpp:239] Failed to open wayland connection
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.406073 addonmanager.cpp:205] Loaded addon wayland
6月 29 12:53:22 desktop fcitx5[1460]: I2025-06-29 12:53:22.406354 addonmanager.cpp:205] Loaded addon waylandim
...
$ journalctl --user -u fcitx5-daemon.service --no-pager
6月 29 12:53:22 desktop systemd[1404]: Started Fcitx5 input method editor.
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.330676 instance.cpp:1394] Override Enabled Addons: {}
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.330752 instance.cpp:1395] Override Disabled Addons: {}
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.336666 addonmanager.cpp:205] Loaded addon imselector
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.340227 addonmanager.cpp:205] Loaded addon quickphrase
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.350024 addonmanager.cpp:205] Loaded addon xcb
6月 29 12:53:22 desktop fcitx5[1436]: E2025-06-29 12:53:22.355254 waylandmodule.cpp:239] Failed to open wayland connection
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.355375 addonmanager.cpp:205] Loaded addon wayland
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.358986 addonmanager.cpp:205] Loaded addon waylandim
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.365320 addonmanager.cpp:205] Loaded addon keyboard
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.367617 addonmanager.cpp:205] Loaded addon clipboard
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.416571 addonmanager.cpp:205] Loaded addon pinyinhelper
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.432097 addonmanager.cpp:205] Loaded addon luaaddonloader
6月 29 12:53:22 desktop fcitx5[1436]: E2025-06-29 12:53:22.437380 addonloader.cpp:95] Failed to create addon: dbus Unable to request dbus name. Is there another fcitx already running?
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437404 addonmanager.cpp:201] Could not load addon dbus
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437619 addonmanager.cpp:308] Unloading addon luaaddonloader
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437644 addonmanager.cpp:308] Unloading addon pinyinhelper
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437667 addonmanager.cpp:308] Unloading addon clipboard
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437711 addonmanager.cpp:308] Unloading addon keyboard
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437864 addonmanager.cpp:308] Unloading addon waylandim
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437893 addonmanager.cpp:308] Unloading addon wayland
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437913 addonmanager.cpp:308] Unloading addon xcb
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.437932 addonmanager.cpp:308] Unloading addon quickphrase
6月 29 12:53:22 desktop fcitx5[1436]: I2025-06-29 12:53:22.438114 addonmanager.cpp:308] Unloading addon imselector
6月 29 12:53:23 desktop systemd[1404]: Started Fcitx5 input method editor.
$ journalctl --user -u niri.service --no-pager
6月 29 12:53:22 desktop systemd[1404]: Starting A scrollable-tiling Wayland compositor...
6月 29 12:53:22 desktop niri[1464]: 2025-06-29T04:53:22.532243Z INFO niri: starting version 25.05.1 (Nixpkgs)
6月 29 12:53:22 desktop niri[1464]: 2025-06-29T04:53:22.540230Z DEBUG niri_config: loaded config from "/home/alice/.config/niri/config.kdl"
6月 29 12:53:22 desktop niri[1464]: 2025-06-29T04:53:22.609393Z INFO niri::backend::tty: using as the render node: "/dev/dri/renderD129"
6月 29 12:53:22 desktop niri[1464]: 2025-06-29T04:53:22.663130Z DEBUG niri::backend::tty: device added: 57856 "/dev/dri/card0"
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.273655Z DEBUG niri::backend::tty: this is the primary node
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.273666Z DEBUG niri::backend::tty: this is the primary render node
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.336304Z DEBUG niri::backend::tty: device changed: 57856
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.423814Z DEBUG niri::backend::tty: new connector: HDMI-A-2 "Samsung Electric Company S27E360 0x304C5430"
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.423836Z DEBUG niri::backend::tty: connecting connector: HDMI-A-2
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.423851Z DEBUG niri::backend::tty: picking mode: Mode { name: "1920x1080", clock: 148500, size: (1920, 1080), hsync: (2008, 2052, 2200), vsync: (1084, 1089, 1125), hskew: 0, vscan: 0, vrefresh: 60, mode_type: ModeTypeFlags(PREFERRED | DRIVER) }
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.423885Z DEBUG niri::backend::tty: error setting max bpc: couldn't find max bpc property
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.455287Z DEBUG niri::niri: putting output HDMI-A-2 at x=0 y=0
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.455309Z DEBUG niri::backend::tty: device added: 57857 "/dev/dri/card1"
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.488180Z DEBUG niri::backend::tty: device changed: 57857
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.492207Z INFO niri: listening on Wayland socket: wayland-1
6月 29 12:53:23 desktop niri[1464]: 2025-06-29T04:53:23.492214Z INFO niri: IPC listening on: /run/user/1000/niri.wayland-1.1464.sock
6月 29 12:53:23 desktop systemd[1404]: Started A scrollable-tiling Wayland compositor.
...
Thanks in advance for any helps!