Closed RoodyPooCandyButt closed 1 month ago
The permission issue is just a warning that can maybe be ignored. I think the true issue is in the code:
battery_state_icons = {
0 : QIcon(dir + 'battery_0.png'),
1 : QIcon(dir + 'battery_1.png'),
2 : QIcon(dir + 'battery_2.png'),
3 : QIcon(dir + 'battery_3.png'),
4 : QIcon(dir + 'battery_4.png'),
5 : QIcon(dir + 'battery_5.png'),
6 : QIcon(dir + 'battery_6.png'),
7 : QIcon(dir + 'battery_7.png'),
'Charging' : QIcon(dir + 'battery_charging.png'),
'Warning' :QIcon(dir + 'battery_alert.png')
}
...
tray_icon.setIcon(battery_state_icons[9])
I haven't looked at this in a while, so I don't quite remember what I was trying to do, but if you sudo nano battery_indicator.py
and change tray_icon.setIcon(battery_state_icons[9])
to tray_icon.setIcon(battery_state_icons["Warning"])
(near the bottom of the file), I think it will do what's expected. Let me know if you can test this fix, and if it works, I'll make a comprehensive cleanup to the code with this included 🙂
Actually, if you don't mind waiting until later today, I went ahead and made some QOL updates. I just need to test it before I push it to main.
Sit tight! I'll @ you when it's done.
Thanks!
My RasPi is out of commission tonight unfortunately 😅 the change I proposed above should get this rolling at least. I'll update this eventually, but it might take up to a week, just FYI
Hey! Thank you for your patience. I was able to get around to fixing this; I tested it on my machine and it works, so hopefully you have the same success. If not, feel free to ping me again with the error message and I'll take a look :)
I am getting the following when I check for errors:
Any idea how to fix it?