[elbe-devel] [PATCH 11/40] pylint: remove/annotate unused imports

Manuel Traut manut at linutronix.de
Fri Sep 14 13:56:23 CEST 2018


debianize.py:     annotate unused imports they are needed
xmldefaults.py:   remove unused import string
xmlpreprocess.py: remove unused import re

Signed-off-by: Manuel Traut <manut at linutronix.de>
---
 elbepack/debianize/debianize.py | 12 ++++--------
 elbepack/xmldefaults.py         |  1 -
 elbepack/xmlpreprocess.py       |  1 -
 3 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/elbepack/debianize/debianize.py b/elbepack/debianize/debianize.py
index efabf72e..3cb92b39 100644
--- a/elbepack/debianize/debianize.py
+++ b/elbepack/debianize/debianize.py
@@ -5,15 +5,11 @@
 
 from npyscreen import NPSAppManaged
 
-# don't remove these imports; even if pylint, etc believes they are unused
-#
-# pylint: disable=unused-import
-
-from elbepack.debianize.kernel import Kernel
-from elbepack.debianize.uboot import UBoot
-from elbepack.debianize.barebox import BareBox
+from elbepack.debianize.kernel import Kernel   #pylint: disable=unused-import
+from elbepack.debianize.uboot import UBoot     #pylint: disable=unused-import
+from elbepack.debianize.barebox import BareBox #pylint: disable=unused-import
 
-from elbepack.debianize.base import DebianizeBase
+from elbepack.debianize.base import DebianizeBase #pylint: disable=unused-import
 
 
 class Debianize (NPSAppManaged):
diff --git a/elbepack/xmldefaults.py b/elbepack/xmldefaults.py
index 1c58b21d..a42df002 100644
--- a/elbepack/xmldefaults.py
+++ b/elbepack/xmldefaults.py
@@ -9,7 +9,6 @@
 from __future__ import print_function
 
 import random
-import string
 import sys
 
 from elbepack.kvm import find_kvm_exe
diff --git a/elbepack/xmlpreprocess.py b/elbepack/xmlpreprocess.py
index 0c6b4902..fdbaee3f 100644
--- a/elbepack/xmlpreprocess.py
+++ b/elbepack/xmlpreprocess.py
@@ -5,7 +5,6 @@
 # SPDX-License-Identifier: GPL-3.0-or-later
 
 import sys
-import re
 from lxml import etree
 from lxml.etree import XMLParser, parse
 from elbepack.archivedir import ArchivedirError, combinearchivedir
-- 
2.19.0.rc2




More information about the elbe-devel mailing list