mirror of https://github.com/zulip/zulip.git
Apply Python 3 futurize transform libmodernize.fixes.fix_xrange_six
Refer to #256
This commit is contained in:
parent
aa505b0d55
commit
b9e792c4e6
|
@ -1,6 +1,8 @@
|
|||
#!/usr/bin/env python2.7
|
||||
from __future__ import absolute_import
|
||||
import xml.etree.ElementTree as ET
|
||||
import subprocess
|
||||
from six.moves import range
|
||||
|
||||
# Generates the favicon images containing unread message counts.
|
||||
|
||||
|
@ -10,7 +12,7 @@ elems = [tree.getroot().findall(
|
|||
".//*[@id='%s']/{http://www.w3.org/2000/svg}tspan" % (name,))[0]
|
||||
for name in ('number_back', 'number_front')]
|
||||
|
||||
for i in xrange(1, 100):
|
||||
for i in range(1, 100):
|
||||
# Prepare a modified SVG
|
||||
s = '%2d' % (i,)
|
||||
for e in elems:
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#!/usr/bin/env python2.7
|
||||
from __future__ import print_function
|
||||
from __future__ import absolute_import
|
||||
import sys
|
||||
import time
|
||||
import optparse
|
||||
|
@ -8,6 +9,7 @@ import random
|
|||
import logging
|
||||
import subprocess
|
||||
import hashlib
|
||||
from six.moves import range
|
||||
|
||||
parser = optparse.OptionParser()
|
||||
parser.add_option('--verbose',
|
||||
|
@ -150,7 +152,7 @@ for (stream, test) in test_streams:
|
|||
zephyr_subs_to_add.append((stream, '*', '*'))
|
||||
|
||||
actually_subscribed = False
|
||||
for tries in xrange(10):
|
||||
for tries in range(10):
|
||||
try:
|
||||
zephyr.init()
|
||||
zephyr._z.subAll(zephyr_subs_to_add)
|
||||
|
|
|
@ -42,6 +42,7 @@ interfaces.
|
|||
|
||||
'''
|
||||
|
||||
from __future__ import absolute_import
|
||||
import sys
|
||||
import logging
|
||||
import logging.handlers
|
||||
|
@ -50,6 +51,7 @@ import re
|
|||
|
||||
import boto.utils
|
||||
import netifaces
|
||||
from six.moves import range
|
||||
|
||||
def address_of(device_id):
|
||||
try:
|
||||
|
|
|
@ -5,6 +5,7 @@ import sys
|
|||
import subprocess
|
||||
from six.moves import filter
|
||||
from six.moves import map
|
||||
from six.moves import range
|
||||
|
||||
class Record:
|
||||
pass
|
||||
|
|
Loading…
Reference in New Issue