Home-manager: Error calling StartServiceByName for org.freedesktop.Notifications: Timeout was reached

I’m still on 22.05 and getting this error with home-manager:

Error calling StartServiceByName for org.freedesktop.Notifications: Timeout was reached

Any ideas?:wink:

Some more context would really help. What program did this error get printed by? What were you trying to do? How is this connecting to home-manager exactly?

It’s when I run

home-manager switch

, like so:

[b0ef@spartacus:~]$ home-manager switch
/nix/store/6cf073z0wvsh6yv15y5zgskg6cm4nrn5-home-manager-generation
Starting Home Manager activation
Activating checkFilesChanged
Activating checkLinkTargets
Activating writeBoundary
Activating installPackages
replacing old 'home-manager-path'
installing 'home-manager-path'
Activating linkGeneration
Cleaning up orphan links from /home/b0ef
No change so reusing latest profile generation 3
Creating home file links in /home/b0ef
Activating onFilesChange
Activating reloadSystemd

There are 46 unread and relevant news items.
Read them by running the command "home-manager news".

Error calling StartServiceByName for org.freedesktop.Notifications: Timeout was reached

is there any way to turn on debug or something, to see which package is generating this error?

This is caused by home-manager itself, here home-manager/home-manager at 176e455371a8371586e8a3ff0d56ee9f3ca2324e · nix-community/home-manager · GitHub

The cause is that home-manager sees the DISPLAY variable set in your environment, and the newsDisplay option defaults to notify, so home-manager is using notify-send to show a notification, but apparently you don’t have a notification service running, thus the error.

I haven’t tried this myself, but from the code, it looks like setting

news.display = "show";

in your home-manager config should stop the error. (Alternatively, getting a notifications service correctly set up would also stop the error.)

2 Likes