ubuntuone-syncdaemon fails to connect when policy prevents it from contacting network-manager
Bug #1062051 reported by
Vincent Ladeuil
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Ubuntu Single Sign On Client | Status tracked in Trunk | |||||
Stable-4-2 |
Fix Released
|
Undecided
|
Unassigned | |||
Trunk |
Fix Released
|
High
|
Alejandro J. Cura | |||
ubuntu-sso-client (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | |||
Raring |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
When doing tests via ssh on a virtual machine (i.e. not connecting via the GUI), using a dedicated dbus sessions (aka via 'dbus-launch'), nm-tool reports 'State: unknown'.
'u1sdtool --connect' then fails to connect.
Stopping the network-manager allows 'u1sdtool --connect' to succeed but is a bit of a big hammer.
This was debugged on IRC with rye who asked me to file this bug.
More details from me or rye on demand ;)
Related branches
lp:~alecu/ubuntu-sso-client/other-nm-errors
- Manuel de la Peña (community): Approve
- dobey (community): Approve
-
Diff: 114 lines (+13/-29)2 files modifiedubuntu_sso/networkstate/linux.py (+7/-11)
ubuntu_sso/networkstate/tests/test_linux.py (+6/-18)
summary: |
- u1sdtool fails to connect when network-manager report unknown state + ubuntuone-syncdaemon fails to connect when policy prevents it from + contacting network-manager |
Changed in ubuntuone-client: | |
assignee: | nobody → Alejandro J. Cura (alecu) |
importance: | Undecided → High |
tags: | added: desktop+ syncdaemon |
affects: | ubuntuone-client → ubuntu-sso-client |
Changed in ubuntu-sso-client (Ubuntu Raring): | |
status: | New → Triaged |
To post a comment you must log in.
def got_error(self, error): exceptions. DBusException) and \
error. get_dbus_ name() == DBUS_UNKNOWN_ SERVICE:
logger. debug(" Network Manager not present")
self. call_result_ cb(ONLINE)
logger. error(" Error contacting NetworkManager: %s" %
str(error) )
self. call_result_ cb(UNKNOWN)
"""Called by DBus when the state is retrieved from NM."""
if isinstance(error, self.dbus.
# Assuming since Network Manager is not installed,
# the user has connected in some other way
else:
This code assumes that the only case we get error from network manager is when it is not running. SERVICE. How about setting ONLINE state on any error?
However, if we don't satisfy "at_console" policy condition (e.g. logging in from SSH) then SD will receive an error which is not DBUS_UNKNOWN_