Revert "Handle python-dbus not installed"
This reverts commit fd22f01b1f21005846bef211851d17f602a7c600. old-commit-hash: a2c6fdd14ce9ef1dfa59db6de91ebf863920d381
This commit is contained in:
@@ -25,11 +25,7 @@ MM_MODEM_ACCESS_TECHNOLOGY_LTE = 1 << 14
|
||||
|
||||
class Tici(HardwareBase):
|
||||
def __init__(self):
|
||||
# TODO: remove when dbus is installed everywhere
|
||||
try:
|
||||
import dbus # pylint: disable=import-error
|
||||
except ImportError:
|
||||
return
|
||||
import dbus # pylint: disable=import-error
|
||||
|
||||
self.bus = dbus.SystemBus()
|
||||
self.nm = self.bus.get_object(NM, '/org/freedesktop/NetworkManager')
|
||||
|
||||
@@ -69,10 +69,7 @@ def clear_locks(root):
|
||||
cloudlog.exception("clear_locks failed")
|
||||
|
||||
def is_on_wifi():
|
||||
try:
|
||||
return HARDWARE.get_network_type() == NetworkType.wifi
|
||||
except Exception:
|
||||
return False
|
||||
return HARDWARE.get_network_type() == NetworkType.wifi
|
||||
|
||||
class Uploader():
|
||||
def __init__(self, dongle_id, root):
|
||||
|
||||
Reference in New Issue
Block a user