examples: rework imports

Remove unused imports and fix import sorting using isort utility.
This commit is contained in:
Yegor Yefremov
2021-02-13 09:40:05 +01:00
committed by Aleksander Morgado
parent 6107774bb2
commit 16d1cf3318
4 changed files with 15 additions and 9 deletions

View File

@@ -18,10 +18,10 @@
# Copyright (C) 2014 Aleksander Morgado <aleksander@aleksander.es> # Copyright (C) 2014 Aleksander Morgado <aleksander@aleksander.es>
# #
import os, sys, gi import gi
gi.require_version('ModemManager', '1.0') gi.require_version('ModemManager', '1.0')
from gi.repository import GLib, GObject, Gio, ModemManager from gi.repository import Gio, GLib, GObject, ModemManager
""" """
The ModemWatcher class is responsible for monitoring ModemManager The ModemWatcher class is responsible for monitoring ModemManager

View File

@@ -18,10 +18,12 @@
# Copyright (C) 2014 Aleksander Morgado <aleksander@aleksander.es> # Copyright (C) 2014 Aleksander Morgado <aleksander@aleksander.es>
# #
import sys, signal import signal
import ModemWatcher
from gi.repository import GLib from gi.repository import GLib
import ModemWatcher
main_loop = None main_loop = None
watcher = None watcher = None

View File

@@ -18,10 +18,12 @@
# Copyright (C) 2019 Aleksander Morgado <aleksander@aleksander.es> # Copyright (C) 2019 Aleksander Morgado <aleksander@aleksander.es>
# #
import sys, signal, gi import sys
import gi
gi.require_version('ModemManager', '1.0') gi.require_version('ModemManager', '1.0')
from gi.repository import GLib, GObject, Gio, ModemManager from gi.repository import Gio, GLib, GObject, ModemManager
if __name__ == "__main__": if __name__ == "__main__":

View File

@@ -18,10 +18,12 @@
# Copyright (C) 2016 Aleksander Morgado <aleksander@aleksander.es> # Copyright (C) 2016 Aleksander Morgado <aleksander@aleksander.es>
# #
import sys, signal, gi import sys
import gi
gi.require_version('ModemManager', '1.0') gi.require_version('ModemManager', '1.0')
from gi.repository import GLib, GObject, Gio, ModemManager from gi.repository import Gio, GLib, GObject, ModemManager
if __name__ == "__main__": if __name__ == "__main__":