dunst-project / dunst

Lightweight and customizable notification daemon
https://dunst-project.org
Other
4.62k stars 342 forks source link

Notification all black on Arch with Xmonad #632

Closed Legogris closed 5 years ago

Legogris commented 5 years ago

I unfortunately don't remember when this started happening, but in a previously working environment dunst is now all black. I think this is different from #225 et al - the time period, size and position matches what I would expect but instead of a notification it's just an all-black box.

Installation info

personinblack commented 5 years ago

I have this same stuff for like a month except it is not black but my wallpaper instead. It makes the window behind it invisible. To fix this problem I have to restart Dunst periodically.

Here is a screenshot (notice the bottom right).

834

Installation info

tsipinakis commented 5 years ago

Huh, that's weird. Can either of you run build from source and run a bisect to see which change broke it?

personinblack commented 5 years ago

Huh, that's weird. Can either of you run build from source and run a bisect to see which change broke it?

Well the thing is I don't know what triggers this stuff :/ So I can't just go through the history and wait for it to happen but I will try.

tsipinakis commented 5 years ago

Oh, from the original issue I thought this was something predictably reproducible on your setup. This is going to be tricky to debug otherwise :/.

I do have one theory on the cause though. Can you try using https://github.com/tsipinakis/dunst/commit/c5b5b0a914aa145ea2e617c84e608f2a6e833544, see if that fixes it?

personinblack commented 5 years ago

Oh, from the original issue I thought this was something predictably reproducible on your setup. This is going to be tricky to debug otherwise :/.

I do have one theory on the cause though. Can you try using tsipinakis@c5b5b0a, see if that fixes it?

I'm going to try this and report back in a few hours. Thanks!

personinblack commented 5 years ago

It's been 6 hours and I haven't experienced any problems at all. I believe this fixes the problem. Thank you @tsipinakis.

personinblack commented 5 years ago

Here I am after a day. The problem is back :( I'm still running the bugfix.

Legogris commented 5 years ago

I am a couple of hours in and so far so good.

personinblack commented 5 years ago

I am a couple of hours in and so far so good.

@Legogris, if we are having the same problem, the problem should come back after a reboot. If not, I have to open up a new issue and try to run a bisect.

Legogris commented 5 years ago

I am a couple of hours in and so far so good.

@Legogris, if we are having the same problem, the problem should come back after a reboot. If not, I have to open up a new issue and try to run a bisect.

This is exactly what happened. Fresh reboot, all black again.

tsipinakis commented 5 years ago

if we are having the same problem, the problem should come back after a reboot

Just to double check, after the reboot you are running the patched version, right? And not letting dbus auto-start the older one?

personinblack commented 5 years ago

if we are having the same problem, the problem should come back after a reboot

Just to double check, after the reboot you are running the patched version, right? And not letting dbus auto-start the older one?

I have the older one removed. My i3 config auto starts the patched one. I will try to run a bisect but I'm too busy with school at the moment :/ Hopefully it will be finished after this week.

ElieLP commented 5 years ago

Same bug for me, I don't know if it's related but it happened the approximately when I changed colors in :

[urgency_low]                                  
    # IMPORTANT: colors have to be defined in quotation marks.
    # Otherwise the "#" and following would be interpreted as a comment.
    background = "#222222"                                                   
    foreground = "#888888"  
    timeout = 10
    # Icon for notifications with low urgency, uncomment to enable
    #icon = /path/to/icon

[urgency_normal]                                      
    background = "#000000"
    foreground = "#ffffff"
    timeout = 10                      
    # Icon for notifications with normal urgency, uncomment to enable 
    #icon = /path/to/icon         

[urgency_critical]
    background = "#900000"
    foreground = "#ffffff"
    frame_color = "#ff0000"                                                 
    timeout = 0                                                                
    # Icon for notifications with critical urgency, uncomment to enable        
    #icon = /path/to/icon

Environnement :

Legogris commented 5 years ago

if we are having the same problem, the problem should come back after a reboot

Just to double check, after the reboot you are running the patched version, right? And not letting dbus auto-start the older one?

Correct.

Ryuuji159 commented 5 years ago

Im having the same problem as him, dunst show transparent with notifications coming from laravel-mix, here is a screenshot 1561073536

tsipinakis commented 5 years ago

@Ryuuji159 and all others that reported this: Is this predictably reproduce-able with a specific notification or does it happen at random times?

Could you also post your dunstrc and the output of dbus-monitor when a notification that causes it to happen goes through?

Ryuuji159 commented 5 years ago

Sorry for the late response here is the output of dbus-monitor

signal time=1561309444.334868 sender=org.freedesktop.DBus -> destination=:1.115 serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string ":1.115"
signal time=1561309444.334938 sender=org.freedesktop.DBus -> destination=:1.115 serial=4 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameLost
   string ":1.115"
signal time=1561309444.946709 sender=:1.4 -> destination=(null destination) serial=15355 path=/StatusNotifierItem; interface=org.kde.StatusNotifierItem; member=NewIcon
signal time=1561309444.946761 sender=:1.4 -> destination=(null destination) serial=15356 path=/StatusNotifierItem; interface=org.kde.StatusNotifierItem; member=NewToolTip
signal time=1561309447.981240 sender=:1.4 -> destination=(null destination) serial=15357 path=/StatusNotifierItem; interface=org.kde.StatusNotifierItem; member=NewIcon
signal time=1561309447.981266 sender=:1.4 -> destination=(null destination) serial=15358 path=/StatusNotifierItem; interface=org.kde.StatusNotifierItem; member=NewToolTip
method call time=1561309450.668914 sender=:1.116 -> destination=org.freedesktop.DBus serial=1 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=Hello
method return time=1561309450.668953 sender=org.freedesktop.DBus -> destination=:1.116 serial=1 reply_serial=1
   string ":1.116"
signal time=1561309450.668968 sender=org.freedesktop.DBus -> destination=(null destination) serial=393 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameOwnerChanged
   string ":1.116"
   string ""
   string ":1.116"
signal time=1561309450.668986 sender=org.freedesktop.DBus -> destination=:1.116 serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string ":1.116"
method call time=1561309450.669572 sender=:1.116 -> destination=org.freedesktop.DBus serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='org.freedesktop.Notifications',interface='org.freedesktop.Notifications',path='/org/freedesktop/Notifications'"
method return time=1561309450.669605 sender=org.freedesktop.DBus -> destination=:1.116 serial=3 reply_serial=2
method call time=1561309450.669668 sender=:1.116 -> destination=org.freedesktop.DBus serial=3 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='org.freedesktop.DBus',interface='org.freedesktop.DBus',member='NameOwnerChanged',path='/org/freedesktop/DBus',arg0='org.freedesktop.Notifications'"
method return time=1561309450.669682 sender=org.freedesktop.DBus -> destination=:1.116 serial=4 reply_serial=3
method call time=1561309450.669689 sender=:1.116 -> destination=org.freedesktop.DBus serial=4 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=StartServiceByName
   string "org.freedesktop.Notifications"
   uint32 0
method return time=1561309450.669704 sender=org.freedesktop.DBus -> destination=:1.116 serial=5 reply_serial=4
   uint32 2
method call time=1561309450.671848 sender=:1.116 -> destination=org.freedesktop.DBus serial=5 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=GetNameOwner
   string "org.freedesktop.Notifications"
method return time=1561309450.671885 sender=org.freedesktop.DBus -> destination=:1.116 serial=6 reply_serial=5
   string ":1.5"
method call time=1561309450.672216 sender=:1.116 -> destination=:1.5 serial=6 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=GetServerInformation
method return time=1561309450.672540 sender=:1.5 -> destination=:1.116 serial=38 reply_serial=6
   string "dunst"
   string "knopwob"
   string "1.4.0 (2019-03-30)"
   string "1.2"
method call time=1561309450.672946 sender=:1.116 -> destination=:1.5 serial=7 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=Notify
   string "notify-send"
   uint32 0
   string "/home/data/src/www.danielcortes.xyz/node_modules/laravel-mix/icons/laravel.png"
   string "Laravel Mix"
   string "Error: /home/data/src/www.danielcortes.xyz/resources/sass/admin.scss
ModuleBuildError: Module build failed (from ./node_modules/sass-loader/lib/loader.js):

}sasdasd
       ^
      Expected "{".
   ╷
40 │ }sasdasd
   │         ^
   ╵
  stdin 40:9  root stylesheet
      in /home/data/src/www.danielcortes.xyz/resources/sass/admin.scss (line 40, column 9)"
   array [
   ]
   array [
      dict entry(
         string "transient"
         variant             int32 1
      )
      dict entry(
         string "urgency"
         variant             byte 1
      )
   ]
   int32 2
method return time=1561309450.674074 sender=:1.5 -> destination=:1.116 serial=39 reply_serial=7
   uint32 8
signal time=1561309450.675719 sender=org.freedesktop.DBus -> destination=:1.116 serial=5 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameLost
   string ":1.116"
signal time=1561309450.675750 sender=org.freedesktop.DBus -> destination=(null destination) serial=394 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameOwnerChanged
   string ":1.116"
   string ":1.116"
   string ""
signal time=1561309450.710547 sender=:1.5 -> destination=:1.116 serial=40 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=NotificationClosed
   uint32 8
   uint32 1
error time=1561309450.710584 sender=org.freedesktop.DBus -> destination=:1.5 error_name=org.freedesktop.DBus.Error.ServiceUnknown reply_serial=40
   string "The name :1.116 was not provided by any .service files"

And my dunstrc

[global]
follow = mouse
geometry = "0x0-20+30"
indicate_hidden = yes
shrink = no
transparency = 0
notification_height = 30
separator_height = 2
padding = 15
horizontal_padding = 20
frame_color = "#aaaaaa"
separator_color = frame
sort = yes
idle_threshold = 120

### Text ###
font = monospace 10
markup = full
format = "<b>%s</b>\n%b"
alignment = center
show_age_threshold = 60
word_wrap = yes
ellipsize = middle
ignore_newline = no
stack_duplicates = true
hide_duplicate_count = false
show_indicators = yes

browser = /usr/bin/firefox-bin -new-tab
always_run_script = true

[urgency_low]
background = "#212121"
foreground = "#EEFFFF"
timeout = 10

[urgency_normal]
background = "#212121"
foreground = "#eeffff"
timeout = 10

[urgency_critical]
background = "#900000"
foreground = "#ffffff"
frame_color = "#ff0000"
timeout = 0

# vim: ft=cfg

And if it helps, I'm using Herbstluftwm as a Window Manager and im not using Compton.

Legogris commented 5 years ago

Sorry for late reply. Sent notification with notify-send hej:

signal time=1566151601.135750 sender=org.freedesktop.DBus -> destination=:1.143 serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string ":1.143"
signal time=1566151601.135835 sender=org.freedesktop.DBus -> destination=:1.143 serial=4 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameLost
   string ":1.143"
method call time=1566151604.417679 sender=:1.144 -> destination=org.freedesktop.DBus serial=1 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=Hello
method return time=1566151604.417715 sender=org.freedesktop.DBus -> destination=:1.144 serial=1 reply_serial=1
   string ":1.144"
signal time=1566151604.417734 sender=org.freedesktop.DBus -> destination=(null destination) serial=650 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameOwnerChanged
   string ":1.144"
   string ""
   string ":1.144"
signal time=1566151604.417761 sender=org.freedesktop.DBus -> destination=:1.144 serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string ":1.144"
method call time=1566151604.418904 sender=:1.144 -> destination=org.freedesktop.DBus serial=2 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='org.freedesktop.Notifications',interface='org.freedesktop.Notifications',path='/org/freedesktop/Notifications'"
method return time=1566151604.418947 sender=org.freedesktop.DBus -> destination=:1.144 serial=3 reply_serial=2
method call time=1566151604.418959 sender=:1.144 -> destination=org.freedesktop.DBus serial=3 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='org.freedesktop.DBus',interface='org.freedesktop.DBus',member='NameOwnerChanged',path='/org/freedesktop/DBus',arg0='org.freedesktop.Notifications'"
method return time=1566151604.419006 sender=org.freedesktop.DBus -> destination=:1.144 serial=4 reply_serial=3
method call time=1566151604.419110 sender=:1.144 -> destination=org.freedesktop.DBus serial=4 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=StartServiceByName
   string "org.freedesktop.Notifications"
   uint32 0
method return time=1566151604.419147 sender=org.freedesktop.DBus -> destination=:1.144 serial=5 reply_serial=4
   uint32 2
method call time=1566151604.419618 sender=:1.144 -> destination=org.freedesktop.DBus serial=5 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=GetNameOwner
   string "org.freedesktop.Notifications"
method return time=1566151604.419660 sender=org.freedesktop.DBus -> destination=:1.144 serial=6 reply_serial=5
   string ":1.2"
method call time=1566151604.420089 sender=:1.144 -> destination=:1.2 serial=6 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=GetServerInformation
method return time=1566151604.420850 sender=:1.2 -> destination=:1.144 serial=65 reply_serial=6
   string "dunst"
   string "knopwob"
   string "v1.4.0"
   string "1.2"
method call time=1566151604.421661 sender=:1.144 -> destination=:1.2 serial=7 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=Notify
   string "notify-send"
   uint32 0
   string ""
   string "hej"
   string ""
   array [
   ]
   array [
      dict entry(
         string "urgency"
         variant             byte 1
      )
   ]
   int32 -1
method return time=1566151604.422556 sender=:1.2 -> destination=:1.144 serial=66 reply_serial=7
   uint32 22
signal time=1566151604.426722 sender=org.freedesktop.DBus -> destination=:1.144 serial=5 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameLost
   string ":1.144"
signal time=1566151604.426771 sender=org.freedesktop.DBus -> destination=(null destination) serial=651 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameOwnerChanged
   string ":1.144"
   string ":1.144"
   string ""
signal time=1566151614.432567 sender=:1.2 -> destination=:1.144 serial=67 path=/org/freedesktop/Notifications; interface=org.freedesktop.Notifications; member=NotificationClosed
   uint32 22
   uint32 1
error time=1566151614.432624 sender=org.freedesktop.DBus -> destination=:1.2 error_name=org.freedesktop.DBus.Error.ServiceUnknown reply_serial=67
   string "The name :1.144 was not provided by any .service files"
method call time=1566151623.621664 sender=:1.9 -> destination=org.freedesktop.DBus serial=488 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=RequestName
   string "org.freedesktop.ReserveDevice1.Audio0"
   uint32 5
signal time=1566151623.621683 sender=org.freedesktop.DBus -> destination=(null destination) serial=652 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameOwnerChanged
   string "org.freedesktop.ReserveDevice1.Audio0"
   string ""
   string ":1.9"
signal time=1566151623.621690 sender=org.freedesktop.DBus -> destination=:1.9 serial=974 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameAcquired
   string "org.freedesktop.ReserveDevice1.Audio0"
method return time=1566151623.621839 sender=org.freedesktop.DBus -> destination=:1.9 serial=975 reply_serial=488
   uint32 1
Legogris commented 5 years ago

Me and @Ryuuji159 have the exact same pattern here.

Let me preface this by saying my understanding of DBus is very limited, but I can kind of see what's going on here:

Not sure how to dig deeper from here, though... Any thoughts @tsipinakis ? I can reproduce this easily and could debug if I get some assistance.

tsipinakis commented 5 years ago

I don't think this is an issue with dbus, if anything it would be on the dunst->X11 interaction side.

The log @Ryuuji159 provided seems normal, I asked for it in an attempt to reproduce this but haven't managed to still. The error you're seeing is most likely because you're using dunstify or notify-send to send a notification - then when that notification is closed dunst tries to tell the client that it did but it has obviously already exited so it fails.

For the actual topic of this issue I'll admit I'm unsure of how to proceed.

I can reproduce this easily and could debug if I get some assistance.

The next best thing to get this moving along would be to pinpoint the exact change that broke it, can you run a bisect and see what that gives?

Legogris commented 5 years ago

Actually, I think I may have figured it out - had somehow missed the FAQ and I now realized I had more than one initialization of dunst. For as long as I can remember, I have just started in in my .xinitrc but now it turns out I have a file under /usr/share/dbus-1/services/org.knopwob.dunst.service. Killing the one from my .xinitrc fixed it, will see if it's good after a reboot with it removed. So local misconfiguration.

I suspect that maybe whatever Arch or AUR package I installed dunst with introduced this in a package upgrade at some point.

EDIT: Yup, confirmed that dunst-git does a make install, thereby installing a systemd service at some point. I guess this can be closed.

tsipinakis commented 5 years ago

Huh that's weird. I'd appreciate it if someone else can also confirm this is the case. Ping @personinblack, @ElieLP.

This strikes me as weird because under normal circumstanced dunst will refuse to start if another notification daemon is running on the same bus. Do you have two dbus instances running by any chance?

Legogris commented 5 years ago

Good question - I don't think I am:

$ sudo ps -Af | grep dbus
dbus       667     1  0 21:46 ?        00:00:00 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
legogris 16768 16704  0 21:47 ?        00:00:00 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
legogris 16907 16901  0 21:47 ?        00:00:00 /usr/bin/dbus-daemon --config-file=/usr/share/defaults/at-spi2/accessibility.conf --nofork --print-address 3
tsipinakis commented 5 years ago

Well the first two dbus processes in that output are the usual ones - the systemwide bus and the user (session) bus respectively.

I'm not sure what that third process is - something from gnome probably.

Since no one else has responded by now I'll assume it's solved.

tsipinakis commented 5 years ago

Oh, if it does re-occur to anyone please do comment and I'll re-open this.

captn3m0 commented 2 years ago

I get this occasionally after a long enough uptime. Runing on ArchLinux+i3

image.

I have the same 3 dbus processes:

sudo ps -Af | grep dbus
dbus         670       1  0 Apr01 ?        00:03:49 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
nemo         818     798  0 Apr01 ?        00:01:59 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
nemo        1139    1131  0 Apr01 ?        00:00:24 /usr/bin/dbus-daemon --config-file=/usr/share/defaults/at-spi2/accessibility.conf --nofork --print-address 11 --address=unix:path=/run/user/1000/at-spi/bus_0

dunst is invoked via i3, and here's the dunstrc

fwsmit commented 2 years ago

Could you open a new issue about this linking to this issue, since there has been no activity on this issue for 3 years. . Also, please specify your Dunst version and the other parts of the bug report template.

otonoton commented 3 months ago

same problem here with 1.5.0 on openbox. after working normally for 2 days now it is always black, even after restarting the daemon.