[py] apply lgtm.com python suggestions
This commit is contained in:
parent
2a182128b9
commit
6937092a66
|
@ -41,8 +41,8 @@ files = [open (x, encoding='utf-8') for x in sys.argv[1:]]
|
|||
|
||||
headers = [[f.readline () for i in range (2)] for f in files]
|
||||
|
||||
data = [{} for f in files]
|
||||
values = [{} for f in files]
|
||||
data = [{} for _ in files]
|
||||
values = [{} for _ in files]
|
||||
for i, f in enumerate (files):
|
||||
for line in f:
|
||||
|
||||
|
@ -215,7 +215,6 @@ for u in uu:
|
|||
if start != last + 1:
|
||||
if start - last <= 1+16*3:
|
||||
print_block (None, last+1, start-1, data)
|
||||
last = start-1
|
||||
else:
|
||||
if last >= 0:
|
||||
ends.append (last + 1)
|
||||
|
|
|
@ -22,8 +22,8 @@ files = [open (x, encoding='utf-8') for x in sys.argv[1:]]
|
|||
headers = [[f.readline () for i in range (2)] for j,f in enumerate(files) if j != 2]
|
||||
headers.append (["UnicodeData.txt does not have a header."])
|
||||
|
||||
data = [{} for f in files]
|
||||
values = [{} for f in files]
|
||||
data = [{} for _ in files]
|
||||
values = [{} for _ in files]
|
||||
for i, f in enumerate (files):
|
||||
for line in f:
|
||||
|
||||
|
@ -488,7 +488,6 @@ for u in uu:
|
|||
if start != last + 1:
|
||||
if start - last <= 1+16*3:
|
||||
print_block (None, last+1, start-1, data)
|
||||
last = start-1
|
||||
else:
|
||||
if last >= 0:
|
||||
ends.append (last + 1)
|
||||
|
|
Loading…
Reference in New Issue