I wanted to get started with developing small extensions in gnome. As far as I understood the guide on debugging, the expected way to test your extension is
dbus-run-session gnome-shell --devkit --wayland
However, this command takes half a minute to run until I can see my window. This is incredible inconvenient for small changes and rapid testing, which I’m looking forward to as I’m quite inexperienced with gjs and also js. Is this really the way it is expected to work? Or is something wrong with my setup?
This is likely due to an issue in xdg-desktop-portal, which waits for the secret service to launch before finishing. Try running with GTK_A11Y=none ADW_DISABLE_PORTAL=1.
Yes, this sounds likely, as the longest break in the process launch occures between
discover_other_daemon: 1GNOME_KEYRING_CONTROL=/run/user/1000/keyring
GNOME Shell-Message: 13:04:34.282: Error connecting to the screencast service
However, setting the env vars didn’t work for me, it is still the same behavior and takes 30 secs…
But I take from your answer @jadahl that it is expected to run much faster. So, I will try to find the problem.
For context, the output of my command:
➜ ~ GTK_A11Y=none ADW_DISABLE_PORTAL=1 dbus-run-session gnome-shell --devkit --wayland
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.Daemon’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.Daemon’
fusermount3: failed to access mountpoint /run/user/1000/gvfs: Permission denied
libmutter-Message: 13:17:27.762: Running GNOME Shell (using mutter 50.2) as a Wayland display server
libmutter-Message: 13:17:27.815: Added device ‘/dev/dri/renderD128’ (i915) using no mode setting.
libmutter-Message: 13:17:27.817: Created gbm renderer for ‘/dev/dri/renderD128’
libmutter-Message: 13:17:27.817: Boot VGA GPU /dev/dri/renderD128 selected as primary
** Message: 13:17:27.819: Obtained a high priority EGL context
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.a11y.Bus’ requested by ‘:1.2’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.a11y.Bus’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
libmutter-Message: 13:17:27.847: Using public X11 display :2, (using unix:/tmp/.X11-unix/X3 for managed services)
(gnome-shell:42717): libmutter-WARNING **: 13:17:27.847: WL: unable to lock lockfile /run/user/1000/wayland-0.lock, maybe another compositor is running
libmutter-Message: 13:17:27.847: Using Wayland display name ‘wayland-1’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
** (gnome-shell:42717): WARNING **: 13:17:27.902: AT-SPI: Could not obtain desktop path or name
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
** (gnome-shell:42717): WARNING **: 13:17:27.908: atk-bridge: GetRegisteredEvents returned message with unknown signature
** (gnome-shell:42717): WARNING **: 13:17:27.908: atk-bridge: get_device_events_reply: unknown signature
GNOME Shell-Message: 13:17:28.172: Unset XDG_SESSION_ID, getCurrentSessionProxy() called outside a user session. Asking logind directly.
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.Shell.Screencast’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.impl.portal.PermissionStore’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.Shell.CalendarServer’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.impl.portal.PermissionStore’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.evolution.dataserver.Sources5’ requested by ‘:1.8’ (uid=1000 pid=42780 comm=“/usr/lib/gnome-shell-calendar-server”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘ca.desrt.dconf’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘ca.desrt.dconf’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.portal.Desktop’ requested by ‘:1.6’ (uid=1000 pid=42767 comm=“/usr/bin/gjs -m /usr/share/gnome-shell/org.gnome.S”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.OnlineAccounts’ requested by ‘:1.9’ (uid=1000 pid=42792 comm=“/usr/lib/evolution-source-registry”)
GNOME Shell-Message: 13:17:28.334: Registering session with GDM
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.portal.Documents’ requested by ‘:1.11’ (uid=1000 pid=42803 comm=“/usr/lib/xdg-desktop-portal”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.Shell.Notifications’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.evolution.dataserver.Sources5’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.portal.Documents’
(process:42762): mdk-WARNING **: 13:17:28.365: Invalid application ID ‘org.gnome.Ptyxis’
fusermount3: failed to access mountpoint /run/user/1000/doc: Permission denied
error: fuse init failed: Can’t mount path /run/user/1000/doc
(/usr/lib/xdg-desktop-portal:42803): xdg-desktop-portal-WARNING **: 13:17:28.374: Document portal fuse mount point unknown: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name :1.12 was not provided by any .service files
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.impl.portal.desktop.gnome’ requested by ‘:1.11’ (uid=1000 pid=42803 comm=“/usr/lib/xdg-desktop-portal”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.evolution.dataserver.Calendar8’ requested by ‘:1.8’ (uid=1000 pid=42780 comm=“/usr/lib/gnome-shell-calendar-server”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.Shell.CalendarServer’
GNOME Shell-Message: 13:17:28.395: Will monitor session 7
goa-daemon-Message: 13:17:28.415: goa-daemon version 3.58.1 starting
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.Identity’ requested by ‘:1.14’ (uid=1000 pid=42808 comm=“/usr/lib/goa-daemon”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.UDisks2VolumeMonitor’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.OnlineAccounts’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.Shell.Notifications’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.Identity’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.portal.IBus’ requested by ‘:1.17’ (uid=1000 pid=42832 comm=“ibus-daemon --panel disable”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.portal.IBus’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.evolution.dataserver.Calendar8’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.evolution.dataserver.AddressBook10’ requested by ‘:1.16’ (uid=1000 pid=42846 comm=“/usr/lib/evolution-calendar-factory”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.UDisks2VolumeMonitor’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.MTPVolumeMonitor’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.MTPVolumeMonitor’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.GPhoto2VolumeMonitor’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.GPhoto2VolumeMonitor’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.GoaVolumeMonitor’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.GoaVolumeMonitor’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.evolution.dataserver.AddressBook10’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.AfcVolumeMonitor’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.AfcVolumeMonitor’
GNOME Shell-Message: 13:17:28.566: Error looking up permission: GDBus.Error:org.freedesktop.portal.Error.NotFound: No entry for geolocation
GNOME Shell-Message: 13:17:28.679: Failed to register AuthenticationAgent
GNOME Shell-Message: 13:17:28.787: Failed to query filesystem: method Gio.File.query_filesystem_info_async: At least 4 arguments required, but only 3 passed
GNOME Shell-Message: 13:17:28.787: Failed to query filesystem: method Gio.File.query_filesystem_info_async: At least 4 arguments required, but only 3 passed
GNOME Shell-Message: 13:17:28.787: Failed to query filesystem: method Gio.File.query_filesystem_info_async: At least 4 arguments required, but only 3 passed
(gnome-shell:42717): GNOME Shell-CRITICAL **: 13:17:28.795: Extension test@test.test: ImportError: Module not found: lib.js
Stack trace:
@resource:///org/gnome/shell/ui/init.js:20:20
(gnome-shell:42717): Gjs-WARNING **: 13:17:28.994: Type GITypeInfo of property NM.Object::client does not match return type GITypeInfo of getter get_client. Falling back to slow path
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gnome.Settings.GlobalShortcutsProvider’ requested by ‘:1.21’ (uid=1000 pid=42839 comm=“/usr/lib/xdg-desktop-portal-gnome”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.Settings.GlobalShortcutsProvider’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.impl.portal.desktop.gnome’
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.impl.portal.desktop.gtk’ requested by ‘:1.11’ (uid=1000 pid=42803 comm=“/usr/lib/xdg-desktop-portal”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.impl.portal.desktop.gtk’
** (xdg-desktop-portal-gtk:43023): WARNING **: 13:17:29.440: AT-SPI: Could not obtain desktop path or name
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
** (xdg-desktop-portal-gtk:43023): WARNING **: 13:17:29.442: atk-bridge: GetRegisteredEvents returned message with unknown signature
** (xdg-desktop-portal-gtk:43023): WARNING **: 13:17:29.442: atk-bridge: get_device_events_reply: unknown signature
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.secrets’ requested by ‘:1.11’ (uid=1000 pid=42803 comm=“/usr/lib/xdg-desktop-portal”)
discover_other_daemon: 1GNOME_KEYRING_CONTROL=/run/user/1000/keyring
GNOME Shell-Message: 13:17:53.203: Error connecting to the screencast service
(org.gnome.Shell.Screencast:42767): Gdk-WARNING **: 13:17:53.344: Cannot get portal org.freedesktop.portal.Settings version: Timeout was reached
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gnome.Shell.Screencast’
(mutter-devkit:42762): Gdk-WARNING **: 13:17:53.392: Cannot get portal org.freedesktop.host.portal.Registry version: Timeout was reached
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.freedesktop.systemd1’ requested by ‘:1.4’ (uid=1000 pid=42754 comm=“/usr/bin/dbus-broker-launch --config-file=/usr/sha”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activated service ‘org.freedesktop.systemd1’ failed: Process org.freedesktop.systemd1 exited with status 1
(/usr/lib/xdg-desktop-portal:42803): xdg-desktop-portal-WARNING **: 13:17:54.476: Failed to create secret proxy: Error calling StartServiceByName for org.freedesktop.secrets: Timeout was reached
(/usr/lib/xdg-desktop-portal:42803): xdg-desktop-portal-WARNING **: 13:17:54.476: No skeleton to export
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.freedesktop.portal.Desktop’
libmutter-Message: 13:17:54.710: Added virtual monitor Meta-0
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Activating service name=‘org.gtk.vfs.Metadata’ requested by ‘:1.0’ (uid=1000 pid=42717 comm=“gnome-shell --devkit --wayland”)
dbus-daemon[42716]: [session uid=1000 pid=42716 pidfd=5] Successfully activated service ‘org.gtk.vfs.Metadata’
GNOME Shell-Message: 13:17:56.966: GNOME Shell started at Tue Jun 09 2026 13:17:28 GMT+0200 (Mitteleuropäische Sommerzeit)
GNOME Shell-Message: 13:17:56.966: Registering display with GDM
It should start more or less instantaneously. See mdk: Disable portals & a11y (!5095) · Merge requests · GNOME / mutter · GitLab for another potential work around (GTK_A11Y=none).
This work around works well enough for me:
mkdir -p /tmp/dev-dbus/dbus-1/services
cat < /tmp/dev-dbus/dbus-1/services/org.freedesktop.secrets.service
[D-BUS Service]
Name=org.freedesktop.secrets
Exec=/bin/false
EOF
env XDG_DATA_DIRS=“/tmp/dev-dbus:$XDG_DATA_DIRS” dbus-run-session gnome-shell --devkit --wayland
Thanks @jadahl for your help!!!