You are not logged in.
In this case (with Python) I don't think so - but imports should be investigated.
With dynamic executables you can use the ldd command.
I forgot to mention in the other post, that you should probably also put the md5sum of batterymon-1.2.0.tar.gz in the PKGBUILD file: md5sums=('23bcd745daf5508005284ebd61c29c2b')
Edit 1: And now that we're at it, pygtk should also be listed as a dependency.
Edit 2: I also suggest changing "You do not seem to have libnotify installed. Notifications won't work." to "You do not seem to have notify-python installed. Notifications won't work.". In Arch notify-python is called python-notify, but notify-python will be more generic I think, as it is it's correct name.
Last edited by Lars Stokholm (2009-05-01 14:47:12)
Offline
Thanks Matthew. I've been using this on lxpanel instead of their super ugly one, and the new tool tips make it super awesome.
Just a couple of bugs I noticed. Tool tip you have remainging instead of remaining. also, when you first unplug the power cord it reads time remaining wrong (mine showed 24+ hours--that would be nice, but it's not possible), it shows it right after a few minutes, but not until it's down to about 95-96%.
Last edited by kperkins (2009-05-01 14:31:15)
Offline
I can't get notifications to work. When I unplug the AC I get this:
ERROR:dbus.connection:Exception in handler for D-Bus signal:
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 214, in maybe_handle_message
self._handler(*args, **kwargs)
File "/usr/bin/batterymon", line 78, in __on_property_modified
self.update()
File "/usr/bin/batterymon", line 64, in update
self.property_modified_handler(present)
File "/usr/bin/batterymon", line 433, in __ac_property_modified_handler
listener.ac_property_modified(present)
File "/usr/bin/batterymon", line 459, in ac_property_modified
self.n.notify("On Battery", "AC adapter unplugged, running on battery","full")
File "/usr/bin/batterymon", line 396, in notify
n.show()
GError: The name org.freedesktop.Notifications was not provided by any .service files
Edit: Seems I need notification-daemon which depends on a lot of crap. Too bad, but I can live with just the icon.
Last edited by Lars Stokholm (2009-05-01 15:07:20)
Offline
md5sum is now added to the pkgbuild and i'll fix the dependancie problems later.
thank
i just noticed on my new openbox install the same problem with notifications i might see if i can find another way as sonata is still able to show notifications but batterymon can't.
i'll also look into the hal problem and the typos later tonight
Thanks for the feed back.
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
i just noticed on my new openbox install the same problem with notifications i might see if i can find another way as sonata is still able to show notifications but batterymon can't.
You've got a point about Sonata: There must be another way. I'm using Openbox too btw.
Offline
Me three on OpenBox.:D
I started the program from the commandline, working as it supposed to be. Got a notification at 15% (just as I would expect), plugged in the powersupply and got a notification for that to.
Everything working just fine I thought, but in the terminal where I ran the command I got the following output:
enne@persephone [~/]
-> 2009-05-01 19:54:08,996 - batterymon - ERROR - org.freedesktop.Hal.NoSuchProperty: No property battery.remaining_time on device with id /org/freedesktop/Hal/devices/computer_power_supply_battery_C1E9
2009-05-01 19:54:08,996 - batterymon - ERROR - org.freedesktop.Hal.NoSuchProperty: No property battery.remaining_time on device with id /org/freedesktop/Hal/devices/computer_power_supply_battery_C1E9
2009-05-01 19:54:09,949 - batterymon - ERROR - org.freedesktop.Hal.NoSuchProperty: No property battery.remaining_time on device with id /org/freedesktop/Hal/devices/computer_power_supply_battery_C1E9
2009-05-01 19:54:09,949 - batterymon - ERROR - org.freedesktop.Hal.NoSuchProperty: No property battery.remaining_time on device with id /org/freedesktop/Hal/devices/computer_power_supply_battery_C1E9
Arch x86_64 on HP 6820s and on HP nx9420. Registered Linux User 350155, since 24-03-2004
"Everyone said that it could not be done, until someone came along who didn't know that."
Offline
that seems to happen if the battery is 100% full and is no longer charging i get it all the time. i need to see if i can hide that
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
Thank you very much for your wonderfull work! This one works perfectly
Regards
nsb
Offline
One little thing... When the battery is charging, tool tip text is on one line. When not charging, tool tip text is split on two lines. It would be nice it the tool tip was a little more consistent. Personally I prefer just one line, with some sort of separation (comma or dash), but I'll leave that decision to you.
Edit: A very minimalistic idea: "<battery level> (<status>)" ie. "45% (charging)", "100% (idle)", "79% (discharging)". No need for a lot of text, eh?
Last edited by Lars Stokholm (2009-05-02 15:08:55)
Offline
Hmm I get some pretty weird errors:
/usr/bin/batterymon:244: GtkWarning: Unable to locate theme engine in module_path: "murrine",
self.tray_object= gtk.StatusIcon()
Traceback (most recent call last):
File "/usr/bin/batterymon", line 518, in <module>
pm = PowerManager()
File "/usr/bin/batterymon", line 423, in __init__
self.adapter = AcAdapter()
File "/usr/bin/batterymon", line 46, in __init__
DBusObject.__init__(self)
File "/usr/bin/batterymon", line 39, in __init__
hal_obj = self.bus.get_object('org.freedesktop.Hal', '/org/freedesktop/Hal/Manager')
File "/usr/lib/python2.6/site-packages/dbus/bus.py", line 244, in get_object
follow_name_owner_changes=follow_name_owner_changes)
File "/usr/lib/python2.6/site-packages/dbus/proxies.py", line 241, in __init__
self._named_service = conn.activate_name_owner(bus_name)
File "/usr/lib/python2.6/site-packages/dbus/bus.py", line 183, in activate_name_owner
self.start_service_by_name(bus_name)
File "/usr/lib/python2.6/site-packages/dbus/bus.py", line 281, in start_service_by_name
'su', (bus_name, flags)))
File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 622, in call_blocking
message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.Hal was not provided by any .service files
Any ideas? Oo
Offline
@Eax: Have you started HAL?
Last edited by Lars Stokholm (2009-05-02 17:38:55)
Offline
@Lars Stokholm:
Nope; I hadn't. Thanks
Hmm, it interferes with WICD >_<
Last edited by Eax (2009-05-02 20:17:46)
Offline
i'm using wicd and batterymon and not had any problems?
What kind of issues are you having?
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
@genisis300: When I installed wicd it asked me to outcomment hal in rc.conf .. Is it safe to remove the "!"?
Offline
remove the ! from wicd or hal?
this is my daemons line
DAEMONS=(@preload @acpid syslog-ng @network @netfs @crond @alsa hal wicd @mpd @cpufreq)
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
Sorry From hal
What does @ do?
Offline
@ starts the daemon in the background. You can speed up your boot by adding @ to a lot of them. Just don't do it with HAL as other daemons might depend on it being started.
Btw, the wiki for Wicd explicitly says you have to add HAL to the daemons array.
Last edited by Lars Stokholm (2009-05-03 15:05:37)
Offline
Lars Stokholm: Okay thanks a lot I remember it as I had to put the ! in front Oo
Last edited by Eax (2009-05-03 15:10:42)
Offline
it send the daemon to the background. (Doesn't wait for it to finish loading)
it can be done on alot of daemons that are not essential to your system loading
Hal must be running before wicd hence there is no @ (if i rember correctly)
Last edited by genisis300 (2009-05-03 15:23:56)
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
i may have found a temp solution to the notification problem,
it appears that there has to be a notification-deamon running for it to work.
so i found xfce4-notifyd a very small notification daemon.
i'm still looking for alternative fixes but this one works at the moment.
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
I'm going to be doing some more work on this in the next day or so.
I'm looking to see if there are any feature requests for the next version?
Regards
Matthew
"is adult entertainment killing our children or is killing our children entertaining adults?" Marilyn Manson
Offline
None other than KISS. If you fix a few things (the ones I've mentioned) I'd say it's perfect, hehe.
Offline
I just installed version 1.2.0-6 from AUR and get this error
$ batterymon
You do not seem to have libnotify installed. Notifications won't work.
Traceback (most recent call last):
File "/usr/bin/batterymon", line 523, in <module>
pm.update()
File "/usr/bin/batterymon", line 441, in update
battery.update()
File "/usr/bin/batterymon", line 122, in update
is_charging = self.__battery.GetProperty('battery.rechargeable.is_charging')
File "/usr/lib/python2.6/site-packages/dbus/proxies.py", line 140, in __call__
**keywords)
File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 622, in call_blocking
message, timeout)
dbus.exceptions.DBusException: org.freedesktop.Hal.NoSuchProperty: No property battery.rechargeable.is_charging on device with id /org/freedesktop/Hal/devices/computer_power_supply_battery_BAT1
libnotify is installed
pacman -Qs libnotify
local/libnotify 0.4.5-1.1
Desktop notification library
Offline
@SiD: The exception has nothing to do with libnotify, but try sending the output of 'lshal -u `hal-find-by-capability --capability battery`'. It seems you're missing "battery.rechargeable.is_charging".
Edit (x 117): F*cked a few things up.
Last edited by Lars Stokholm (2009-05-11 20:25:23)
Offline
I just installed version 1.2.0-6 from AUR and get this error
$ batterymon You do not seem to have libnotify installed. Notifications won't work. ...
Did you see this:
...
Edit 2: I also suggest changing "You do not seem to have libnotify installed. Notifications won't work." to "You do not seem to have notify-python installed. Notifications won't work.". In Arch notify-python is called python-notify, but notify-python will be more generic I think, as it is it's correct name.
Not sure, but I would guess you don't have python-notify installed.
Offline