Closed ammgws closed 2 years ago
I think this is because in v0.22 we defaulted to 0
for the charge etc when the DBus method call failed in order to allow for missing devices, whereas that logic is not present in v0.30.
For completeness' sake, i think this error also occurs if the device is connected but the charge can't be read, even if the charge isn't needed because it isn't used in the format string/block coloration
So you can't even get the charge via busctl --user get-property org.kde.kdeconnect /modules/kdeconnect/devices/yourdeviceid/battery org.kde.kdeconnect.device.battery charge
?
What version of kdeconnect are you using?
Currently not on a LAN so i can't test but will check later
Yes the bus device just doesn't have a /battery
object:
$ busctl --user tree org.kde.kdeconnect
├─/MainApplication
├─/modules
│ └─/modules/kdeconnect
│ └─/modules/kdeconnect/devices
│ └─/modules/kdeconnect/devices/7814dd5c9a77a7b2
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/bigscreen
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/connectivity_report
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/contacts
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/findmyphone
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/findthisdevice
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/mprisremote
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/notifications
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/photo
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/ping
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/remotecontrol
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/remotekeyboard
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/sftp
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/share
│ ├─/modules/kdeconnect/devices/7814dd5c9a77a7b2/sms
│ └─/modules/kdeconnect/devices/7814dd5c9a77a7b2/telephony
└─/org
└─/org/kde
└─/org/kde/kdeconnect
└─/org/kde/kdeconnect/daemon
What phone is it? Wonder if it's a bug with kdeconnect itself
Moto G7, about as stock as stock android gets. ¯\_(ツ)_/¯
Does 7400195553777ec3fd9224b2c7aaf00b5a7305cc fix this issue?
Yes, but as soon as the notification count drops to 0
i get
Yeah, documentation is a bit out of sync with the code. Right now notif_count
is not set if there are no notifications, because you might want to display something different than zero. IDK if it's practical.
Either docs or code should be changed. Not sure which behavior is better.
Sometimes I wish the config was in lua
and the format was just a function
(similar to lualine
in neovim
).
Ahh makes sense. Sure why not, could be useful
Another nit: After booting, the block always shows an the error failed to get is_reachable
because the device isn't connected yet (no such path /modules/kdeconnect/devices/7814dd5c9a77a7b2
) and then doesn't update once it does connect. Only when i reload using USR2 or reloading i3 it shows as normal.
@GladOSkar try the latest commit
Fixed. Thanks!
Seems resolved
v0.22
v0.30