Commit f8fc08f1 authored by Bryton Lacquement's avatar Bryton Lacquement 🚪

genbt5list: remove the use of six

This script should only depend on the standard library, for convenience.
parent dba1a129
...@@ -40,10 +40,19 @@ try: ...@@ -40,10 +40,19 @@ try:
except ImportError: except ImportError:
from cgi import escape from cgi import escape
from base64 import b64encode from base64 import b64encode
from six import BytesIO from io import BytesIO
from hashlib import sha1 from hashlib import sha1
from six.moves.urllib.parse import unquote try:
import six from urllib.parse import unquote
except ImportError:
from urllib import unquote
if sys.version_info[0] == 3:
def iteritems(d):
return iter(d.items())
else:
def iteritems(d):
return d.iteritems()
# Order is important for installation # Order is important for installation
# We want to have: # We want to have:
...@@ -152,7 +161,7 @@ force_install ...@@ -152,7 +161,7 @@ force_install
def __iter__(self): def __iter__(self):
self['revision'] = self.revision.digest() self['revision'] = self.revision.digest()
return iter(sorted(six.iteritems(self))) return iter(sorted(iteritems(self)))
@classmethod @classmethod
def fromTar(cls, tar): def fromTar(cls, tar):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment