[elbe-devel] [PATCH 04/10] fix BadStatusLine import for python3

Manuel Traut manut at linutronix.de
Fri Sep 29 00:11:40 CEST 2017


Signed-off-by: Manuel Traut <manut at linutronix.de>
---
 elbepack/commands/control.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/elbepack/commands/control.py b/elbepack/commands/control.py
index 83041beb..e01a8b84 100755
--- a/elbepack/commands/control.py
+++ b/elbepack/commands/control.py
@@ -30,7 +30,10 @@ try:
 except ImportError:
     from urllib2 import URLError
 
-from httplib import BadStatusLine
+try:
+    from http.client import BadStatusLine
+except ImportError:
+    from httplib import BadStatusLine
 
 from elbepack.soapclient import ClientAction, ElbeSoapClient
 from elbepack.version import elbe_version
-- 
2.14.1




More information about the elbe-devel mailing list