From 7562655cf4bf28a1ebd6c458334da0c166f34e61 Mon Sep 17 00:00:00 2001 From: efkin Date: Mon, 13 Mar 2017 21:17:18 +0100 Subject: [refactor] Improve python3 compatibility With this commit all tests on py34 tox environment are collected. --- server/src/leap/soledad/server/__init__.py | 2 +- server/src/leap/soledad/server/gzip_middleware.py | 2 +- server/src/leap/soledad/server/sync.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'server/src/leap') diff --git a/server/src/leap/soledad/server/__init__.py b/server/src/leap/soledad/server/__init__.py index 5bed22c9..6640bab4 100644 --- a/server/src/leap/soledad/server/__init__.py +++ b/server/src/leap/soledad/server/__init__.py @@ -82,7 +82,7 @@ documents on the shared database is handled by `leap.soledad.server.auth` module. """ -import urlparse +import six.moves.urllib.parse as urlparse import sys from leap.soledad.common.l2db.remote import http_app, utils diff --git a/server/src/leap/soledad/server/gzip_middleware.py b/server/src/leap/soledad/server/gzip_middleware.py index 986c5738..c77f9f67 100644 --- a/server/src/leap/soledad/server/gzip_middleware.py +++ b/server/src/leap/soledad/server/gzip_middleware.py @@ -17,7 +17,7 @@ """ Gzip middleware for WSGI apps. """ -import StringIO +from six import StringIO from gzip import GzipFile diff --git a/server/src/leap/soledad/server/sync.py b/server/src/leap/soledad/server/sync.py index b553a056..6791c06c 100644 --- a/server/src/leap/soledad/server/sync.py +++ b/server/src/leap/soledad/server/sync.py @@ -18,7 +18,7 @@ Server side synchronization infrastructure. """ import time -from itertools import izip +from six.moves import zip as izip from leap.soledad.common.l2db import sync from leap.soledad.common.l2db.remote import http_app -- cgit v1.2.3