From aef293fbca51e55f7dd53d4c6ba28daa46273248 Mon Sep 17 00:00:00 2001 From: Itamar Turner-Trauring Date: Mon, 14 Sep 2020 14:03:48 -0400 Subject: [PATCH] Port to Python 3. --- src/allmydata/storage/common.py | 12 +++++++++++- src/allmydata/util/_python3.py | 1 + 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/allmydata/storage/common.py b/src/allmydata/storage/common.py index 55036eea7..cb6116e5b 100644 --- a/src/allmydata/storage/common.py +++ b/src/allmydata/storage/common.py @@ -1,4 +1,14 @@ -from future.utils import PY3 +""" +Ported to Python 3. +""" +from __future__ import unicode_literals +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +from future.utils import PY2, PY3 +if PY2: + from future.builtins import filter, map, zip, ascii, chr, hex, input, next, oct, open, pow, round, super, bytes, dict, list, object, range, str, max, min # noqa: F401 import os.path from allmydata.util import base32 diff --git a/src/allmydata/util/_python3.py b/src/allmydata/util/_python3.py index f612d35df..51cf8018e 100644 --- a/src/allmydata/util/_python3.py +++ b/src/allmydata/util/_python3.py @@ -35,6 +35,7 @@ PORTED_MODULES = [ "allmydata.immutable.happiness_upload", "allmydata.interfaces", "allmydata.monitor", + "allmydata.storage.common", "allmydata.storage.crawler", "allmydata.storage.expirer", "allmydata.storage.mutable",