1
0
mirror of https://github.com/django/django.git synced 2025-10-26 15:16:09 +00:00

Fixed E227 pep8 warnings

This commit is contained in:
Tim Graham
2013-10-21 08:52:21 -04:00
parent b289fcf1bf
commit 499cd912ca
6 changed files with 33 additions and 33 deletions

View File

@@ -814,11 +814,11 @@ def filesizeformat(bytes):
filesize_number_format = lambda value: formats.number_format(round(value, 1), 1)
KB = 1<<10
MB = 1<<20
GB = 1<<30
TB = 1<<40
PB = 1<<50
KB = 1 << 10
MB = 1 << 20
GB = 1 << 30
TB = 1 << 40
PB = 1 << 50
if bytes < KB:
value = ungettext("%(size)d byte", "%(size)d bytes", bytes) % {'size': bytes}

View File

@@ -41,7 +41,7 @@ class Lexer(object):
groupid = "t%d" % tok.id
self.toks[groupid] = tok
parts.append("(?P<%s>%s)" % (groupid, tok.regex))
self.regexes[state] = re.compile("|".join(parts), re.MULTILINE|re.VERBOSE)
self.regexes[state] = re.compile("|".join(parts), re.MULTILINE | re.VERBOSE)
self.state = first

View File

@@ -22,7 +22,7 @@ capfirst = lambda x: x and force_text(x)[0].upper() + force_text(x)[1:]
capfirst = allow_lazy(capfirst, six.text_type)
# Set up regular expressions
re_words = re.compile(r'<.*?>|((?:\w[-\w]*|&.*?;)+)', re.U|re.S)
re_words = re.compile(r'<.*?>|((?:\w[-\w]*|&.*?;)+)', re.U | re.S)
re_tag = re.compile(r'<(/)?([^ ]+?)(?:(\s*/)| .*?)?>', re.S)