That error is expected: FocusApp (like Eval, ShowOSD, screenshots) is gated in gnome-shell behind a hardcoded D-Bus sender allowlist, and a call from your terminal isn't on it. The allowlist only contains org.gnome.Settings, org.gnome.SettingsDaemon.MediaKeys, and org.freedesktop.impl.portal.desktop.gnome (shellDBus.js). So there's no way to call it from a plain script, and it wouldn't have done what you want anyway: it just highlights an app in the overview's app grid, it doesn't raise a window.
The working solution is the Activate Window By Title Shell extension, which exposes exactly the D-Bus method you need and has no sender allowlist:
Install it from extensions.gnome.org (search "Activate Window By Title") or clone it into ~/.local/share/gnome-shell/extensions/, then re-enable it (X11: restart the shell; Wayland: log out/in).
It returns true/false for found/not found, and also offers activateByTitle (exact), activateByPrefix, activateBySuffix, and activateByWmClass if matching by class is more stable than the title (README).
The run-or-raise extension I mentioned earlier also works from a terminal, since its D-Bus interface is gated only by its own gsettings toggle, not by a sender allowlist. Either extension solves your problem; Activate Window By Title is the most direct fit for "raise by title".
Nov 16, 8:12pm
This is a shared conversation and may include unverified content that doesn't reflect Mistral AI's views. Login to resume chatting.
This is a shared conversation and may include unverified content that doesn't reflect Mistral AI's views. Login to resume chatting.