question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Battery low notifications go away with `dunst`

See original GitHub issue

yesterday, thanks to @m-col, I manage to have beautiful popup notifications for my battery from within qtile’s bar and even sound and brightness bars as I change them with the keyboard: notifications dunst However it is still not behaving quite as I expected.

I expected the notifications for a low battery to be of urgent/critical priority and it is red indeed. I configured my dunst so that low and normal notifications go away quite quicly, but critical/red ones never go away!

This is what I observe when I run either

notify-send "ERROR" "this is an error" -u critical
notify-send "NORMAL" "this is a normal message" -u normal
notify-send "LOW" "this is nothing important" -u low

or

dunstify "ERROR" "this is an error" -u critical
dunstify "NORMAL" "this is a normal message" -u normal
dunstify "LOW" "this is nothing important" -u low

But this is not the case with the critical battery low notifications from qtile.

I do not really understand the code of the libqtile.widget.Battery class, could anyone help fix that?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
elParaguayocommented, Feb 18, 2022

The widget does send messages marked as “urgent”. However, I suspect your issue is that the notification is also sent with a set timeout (10 seconds) which dunst is, presumably, honouring.

1reaction
elParaguayocommented, Feb 18, 2022

The widget should send an urgent notification so something’s going wrong by the sounds of it. Let me take a look.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[SOLVED] Battery notifications with dunst and notify-send ...
I'd like to get desktop notifications when my laptop battery is running low. I have dunst installed and this works fine for notifications...
Read more >
[Enchancement] Low battery notification via dunst #90 - GitHub
Sometimes i always forgot what battery im on, especially when it's under 30%. This would be a small yet useful script for the...
Read more >
Battery-low alerts and AC-in notifications? : r/i3wm - Reddit
Just went through this myself. cbattcion package did the trick for me. dunst does the dirty work of placing messages on screen. Docs...
Read more >
How To Get Battery Notifications on Arch Linux - YouTube
Do you miss getting low battery alerts on your laptop from the sad old days when you used Windows or Ubuntu? Do you...
Read more >
How to get Battery notification on Linux | 2DayGeek
Method-1: Receive an alert, when the battery level is above 95% or below 20% ... This shell script runs in the background on...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found