[wicd-curses]Unhandle expection in setup_dbus
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
wicd |
Fix Committed
|
Low
|
Unassigned |
Bug Description
Hi,
I have been using wicd and wicd-curses for almost one years in my Archlinux. It works great and helps me a lot. But I also find out that if I execute wicd-curses when wicd does not start, I got stuff like:
$ wicd-curses
Can't connect to the daemon, trying to start it automatically...
Traceback (most recent call last):
File "/usr/share/
setup_dbus()
File "/usr/share/
dbus_ifaces = dbusmanager.
File "/usr/lib/
return DBUS_MANAGER.
File "/usr/lib/
if not self._dbus_ifaces: connect_to_dbus()
File "/usr/lib/
return DBUS_MANAGER.
File "/usr/lib/
proxy_obj = self._bus.
File "/usr/lib/
follow_
File "/usr/lib/
self.
File "/usr/lib/
self.
File "/usr/lib/
'su', (bus_name, flags)))
File "/usr/lib/
message, timeout)
dbus.exceptions
It seems to be caused by missing setting of dbus. But I think wicd-curses should give some nice message in such cases. So I made a little modify in wicd-curses.py, and It will show like:
$ python2 -O wicd-curses.py
Can't connect to the daemon, trying to start it automatically...
Failed to start wicd automatically.
now.
My patch is naive. Here is the result of diff. I havn't submit any patch before, so sorry for the poor format.
$ diff wicd-curses.py wicd-curses.py.old
1030,1038c1030,1034
< try:
< bus = dbusmanager.
< dbus_ifaces = dbusmanager.
< daemon = dbus_ifaces[
< wireless = dbus_ifaces[
< wired = dbus_ifaces[
< except DBusException:
< print 'Failed to start wicd automatically.
< sys.exit(3)
---
> bus = dbusmanager.
> dbus_ifaces = dbusmanager.
> daemon = dbus_ifaces[
> wireless = dbus_ifaces[
> wired = dbus_ifaces[
regards,
Liuzhiyou
Related branches
Changed in wicd: | |
status: | New → Fix Committed |
Changed in wicd: | |
importance: | Undecided → Low |
Changed in wicd: | |
milestone: | none → 1.7.5 |
assignee: | nobody → Tom Van Braeckel (tomvanbraeckel) |
Changed in wicd: | |
milestone: | 1.7.5 → 1.7.3 |