FS#21984 - [conky] 1.8.1-1 No support for POWER_SUPPLY_POWER_NOW

Attached to Project: Arch Linux
Opened by Tiago Vale (tvale) - Saturday, 04 December 2010, 21:34 GMT
Last edited by Gaetan Bisson (vesath) - Monday, 06 December 2010, 21:42 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Gaetan Bisson (vesath)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
Apparently, the POWER_SUPPLY_CURRENT_NOW entry in the sysfs /sys/class/power_supply/BAT?/uevent and /sys/class/power_supply/BAT?/current_now have been deprecated in favor of POWER_SUPPLY_POWER_NOW and power_now, respectively.
Since I upgraded to kernel 2.6.36.1 conky displayed "unknown" in the battery time either charging or discharging, because it didn't look for the aforementioned entry in the source code.
Attached goes a patch applied to the 1.8.1-1 package source code that fixed the problem for me. I'm also reporting it upstream at http://sourceforge.net/tracker/?group_id=143975&atid=757310.
Sorry if this report is wrong in any way, it's the first time I've ever tried to help.

Additional info:
* version: 1.8.1-1
* http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532000
* https://bbs.archlinux.org/viewtopic.php?pid=861566

Steps to reproduce:
Simply boot your computer with conky displaying ${battery_time BAT?}.
This task depends upon

Closed by  Gaetan Bisson (vesath)
Monday, 06 December 2010, 21:42 GMT
Reason for closing:  Implemented
Comment by Gaetan Bisson (vesath) - Monday, 06 December 2010, 21:41 GMT
That is one of the best written bug reports I have read in ages. Good work! :)

So this kernel change will actually affect more things than just conky (implying that conky is maybe not the best place to fix it), and upstream hasn't responded to your report yet. However, since the patch is clean and tiny, I don't think it harms to include it and make life better for people like you (I still have everything "current") until upstream fixes it.

conky-1.8.1-2 should soon reach [extra].

Loading...