#1122638 sway-notification-center: swaync.service fails to start

Package:
sway-notification-center
Source:
sway-notification-center
Description:
simple notification daemon for sway
Submitter:
Sam Coulter
Date:
2025-12-13 03:55:01 UTC
Severity:
normal
#1122638#5
Date:
2025-12-12 02:55:05 UTC
From:
To:
Dear Maintainer,

After installing the sway-notification-center package, the user service
unit 'swaync.service' does not appear to run without errors when logging
in to a sway session (via greetd + tuigreet)

The service can be manually started with `systemctl --user start swaync`
after login though, and then it appears to work fine.

Output of `journalctl --user -u swaync`:

```
Dec 11 18:47:44 pc systemd[1587]: Starting swaync.service - Swaync notification daemon...
Dec 11 18:47:44 pc swaync[165918]: Starting SwayNotificationCenter version swaync 0.12.3
Dec 11 18:47:44 pc swaync[165918]: Failed to open display
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Main process exited, code=exited, status=1/FAILURE
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:44 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Scheduled restart job, restart counter is at 2.
Dec 11 18:47:44 pc systemd[1587]: Starting swaync.service - Swaync notification daemon...
Dec 11 18:47:44 pc swaync[165937]: Starting SwayNotificationCenter version swaync 0.12.3
Dec 11 18:47:44 pc swaync[165937]: Failed to open display
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Main process exited, code=exited, status=1/FAILURE
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:44 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Scheduled restart job, restart counter is at 3.
Dec 11 18:47:44 pc systemd[1587]: Starting swaync.service - Swaync notification daemon...
Dec 11 18:47:44 pc swaync[166012]: Starting SwayNotificationCenter version swaync 0.12.3
Dec 11 18:47:44 pc swaync[166012]: Failed to open display
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Main process exited, code=exited, status=1/FAILURE
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:44 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:44 pc systemd[1587]: swaync.service: Scheduled restart job, restart counter is at 4.
Dec 11 18:47:44 pc systemd[1587]: Starting swaync.service - Swaync notification daemon...
Dec 11 18:47:45 pc swaync[166018]: Starting SwayNotificationCenter version swaync 0.12.3
Dec 11 18:47:45 pc swaync[166018]: Failed to open display
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Main process exited, code=exited, status=1/FAILURE
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:45 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Scheduled restart job, restart counter is at 5.
Dec 11 18:47:45 pc systemd[1587]: Starting swaync.service - Swaync notification daemon...
Dec 11 18:47:45 pc swaync[166026]: Starting SwayNotificationCenter version swaync 0.12.3
Dec 11 18:47:45 pc swaync[166026]: Failed to open display
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Main process exited, code=exited, status=1/FAILURE
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:45 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Scheduled restart job, restart counter is at 6.
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Start request repeated too quickly.
Dec 11 18:47:45 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:45 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
Dec 11 18:47:53 pc systemd[1587]: swaync.service: Start request repeated too quickly.
Dec 11 18:47:53 pc systemd[1587]: swaync.service: Failed with result 'exit-code'.
Dec 11 18:47:53 pc systemd[1587]: Failed to start swaync.service - Swaync notification daemon.
```

#1122638#10
Date:
2025-12-13 03:53:37 UTC
From:
To:
As a workaround I have disabled the swaync.service unit and simply
launch swaync via `exec swaync` in the sway config - which appears to
be the launch method recommended by the sway and swaync authors.
service
logging
swaync`
notification daemon...
version swaync 0.12.3
exited, code=exited, status=1/FAILURE
'exit-code'.
Swaync notification daemon.
job, restart counter is at 2.
notification daemon...
version swaync 0.12.3
exited, code=exited, status=1/FAILURE
'exit-code'.
Swaync notification daemon.
job, restart counter is at 3.
notification daemon...
version swaync 0.12.3
exited, code=exited, status=1/FAILURE
'exit-code'.
Swaync notification daemon.
job, restart counter is at 4.
notification daemon...
version swaync 0.12.3
exited, code=exited, status=1/FAILURE
'exit-code'.
Swaync notification daemon.
job, restart counter is at 5.
notification daemon...
version swaync 0.12.3
exited, code=exited, status=1/FAILURE
'exit-code'.
Swaync notification daemon.
job, restart counter is at 6.
repeated too quickly.
'exit-code'.
Swaync notification daemon.
repeated too quickly.
'exit-code'.
Swaync notification daemon.