mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-24 01:40:38 +01:00
clients/tests: fix unstable tests for Python2 vs. Python3
Currently, nmcli does not sort the list of available connections for display. Instead, it shows them in the order as NetworkManager exposes them on D-Bus. Previously, test-networkmanager-service.py, would generate the list of available connections by iterating the connections dictionary. In Python (at least until Python 3.6), the order when iterating over dictionaries is undefined. This inconsistancy lets tests behave differently depending on the python version. Possibly with Python 3.4 and 3.5, tests might even behave differently between individual runs (since Python there uses siphash with a randomized hash seed).
This commit is contained in:
parent
fb5f555a54
commit
9a14f9caa5
13 changed files with 65 additions and 59 deletions
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]:dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]:dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]:dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]:dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]:dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]:dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]:dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]:dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]:dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]:dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]:dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]:dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]:dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]:dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]:dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]:dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS:/org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]:UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]:5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]:UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: UUID-ethernet-REPLACED-REPLACED-REPL | ethernet
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: (null) | (null)
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: (null) | (null)
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -55,10 +55,10 @@ DHCP6.OPTION[1]: dhcp-6-opt-1 = val-1
|
|||
DHCP6.OPTION[2]: dhcp-6-opt-5 = val-5
|
||||
DHCP6.OPTION[3]: dhcp-6-opt-6 = val-6
|
||||
DHCP6.OPTION[4]: dhcp-6-opt-8 = val-8
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{3,2,1}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: (null) | (null)
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTION-PATHS: /org/freedesktop/NetworkManager/Settings/{2,1,3}
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[1]: UUID-con-xx1-REPLACED-REPLACED-REPLA | con-xx1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[2]: 5fcfd6d7-1e63-3332-8826-a7eda103792d | con-1
|
||||
CONNECTIONS.AVAILABLE-CONNECTIONS[3]: (null) | (null)
|
||||
|
||||
<<<
|
||||
stderr: 0 bytes
|
||||
|
|
|
|||
|
|
@ -526,11 +526,8 @@ class ExportedObj(dbus.service.Object):
|
|||
|
||||
@staticmethod
|
||||
def to_path_array(src):
|
||||
array = dbus.Array([], signature=dbus.Signature('o'))
|
||||
if src is not None:
|
||||
for o in src:
|
||||
array.append(ExportedObj.to_path(o))
|
||||
return array
|
||||
return dbus.Array([ExportedObj.to_path(o) for o in src] if src else [],
|
||||
signature=dbus.Signature('o'))
|
||||
|
||||
@staticmethod
|
||||
def to_path(src):
|
||||
|
|
@ -773,7 +770,7 @@ class Device(ExportedObj):
|
|||
return False
|
||||
|
||||
def available_connections_get(self):
|
||||
return [c for c in gl.settings.connections.values() if self.connection_is_available(c)]
|
||||
return [c for c in gl.settings.get_connections() if self.connection_is_available(c)]
|
||||
|
||||
def available_connections_update(self):
|
||||
self._dbus_property_set(IFACE_DEVICE, PRP_DEVICE_AVAILABLE_CONNECTIONS,
|
||||
|
|
@ -1680,8 +1677,17 @@ class Settings(ExportedObj):
|
|||
def get_connection(self, path):
|
||||
return self.connections[path]
|
||||
|
||||
def get_connections(self, stable_order = True):
|
||||
cons = list(self.connections.values())
|
||||
if stable_order:
|
||||
cons.sort(key = lambda c: (Util.random_int(c.get_id()), Util.random_int(c.path)))
|
||||
return cons
|
||||
|
||||
def get_connection_paths(self, stable_order = True):
|
||||
return [c.path for c in self.get_connections(stable_order = stable_order)]
|
||||
|
||||
def find_connections(self, path = None, con_id = None, con_uuid = None):
|
||||
for c in self.connections.values():
|
||||
for c in self.get_connections():
|
||||
if path is not None:
|
||||
if c.path != path:
|
||||
continue
|
||||
|
|
@ -1695,7 +1701,7 @@ class Settings(ExportedObj):
|
|||
|
||||
@dbus.service.method(dbus_interface=IFACE_SETTINGS, in_signature='', out_signature='ao')
|
||||
def ListConnections(self):
|
||||
return self.connections.keys()
|
||||
return self.get_connection_paths()
|
||||
|
||||
@dbus.service.method(dbus_interface=IFACE_SETTINGS, in_signature='a{sa{sv}}', out_signature='o')
|
||||
def AddConnection(self, con_hash):
|
||||
|
|
@ -1706,13 +1712,13 @@ class Settings(ExportedObj):
|
|||
con_inst = Connection(self.c_counter, con_hash, do_verify_strict)
|
||||
|
||||
uuid = con_inst.get_uuid()
|
||||
if uuid in [c.get_uuid() for c in self.connections.values()]:
|
||||
if uuid in [c.get_uuid() for c in self.get_connections(stable_order = False)]:
|
||||
raise BusErr.InvalidSettingException('cannot add duplicate connection with uuid %s' % (uuid))
|
||||
|
||||
con_inst.export()
|
||||
self.connections[con_inst.path] = con_inst
|
||||
self.NewConnection(con_inst.path)
|
||||
self._dbus_property_set(IFACE_SETTINGS, PRP_SETTINGS_CONNECTIONS, dbus.Array(self.connections.keys(), 'o'))
|
||||
self._dbus_property_set(IFACE_SETTINGS, PRP_SETTINGS_CONNECTIONS, dbus.Array(self.get_connection_paths(), 'o'))
|
||||
|
||||
if self.remove_next_connection:
|
||||
self.remove_next_connection = False
|
||||
|
|
@ -1729,7 +1735,7 @@ class Settings(ExportedObj):
|
|||
|
||||
def delete_connection(self, con_inst):
|
||||
del self.connections[con_inst.path]
|
||||
self._dbus_property_set(IFACE_SETTINGS, PRP_SETTINGS_CONNECTIONS, dbus.Array(self.connections.keys(), 'o'))
|
||||
self._dbus_property_set(IFACE_SETTINGS, PRP_SETTINGS_CONNECTIONS, dbus.Array(self.get_connection_paths(), 'o'))
|
||||
con_inst.Removed()
|
||||
con_inst.unexport()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue