Skip to content

Commit 7eb39e8

Browse files
authored
Update terminal.py
Update authentication.py liftoff#602 liftoff#602 by xlorepdarkhelm
1 parent ebda314 commit 7eb39e8

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

terminal/terminal.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,6 @@
152152
from datetime import datetime, timedelta
153153
from functools import partial
154154
from collections import defaultdict
155-
from itertools import imap, izip
156155
try:
157156
from collections import OrderedDict
158157
except ImportError: # Python <2.7 didn't have OrderedDict in collections
@@ -165,6 +164,11 @@
165164
logging.error(
166165
"...or download it from http://pypi.python.org/pypi/ordereddict")
167166
sys.exit(1)
167+
try:
168+
from itertools import imap, izip
169+
pass
170+
except ImportError: # Python 3 doesn't have imap or izip in itertool
171+
imap, izip = map, zip
168172
try:
169173
xrange = xrange
170174
except NameError: # Python 3 doesn't have xrange()

0 commit comments

Comments
 (0)