Skip to content

Commit 15c63f2

Browse files
fix missing test related to prev commit
1 parent 88ec1ab commit 15c63f2

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

tests/test_vdf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,7 @@ def test_parse_exceptions(self):
306306
'"asd" "123"\n"zxc" "333"\n"',
307307
'asd 123\nzxc 333\n"',
308308
'"asd\n\n\n\n\nzxc',
309+
'"asd" "bbb\n\n\n\n\nzxc',
309310

310311
# one too many closing parenthasis
311312
'"asd"\n{\n"zxc" "123"\n}\n}\n}\n}\n',

vdf/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ def parse(fp, mapper=dict):
8585
if not match:
8686
try:
8787
line += next(fp)
88+
continue
8889
except StopIteration:
8990
raise SyntaxError("vdf.parse: unexpected EOF (open key quote?)")
90-
continue
9191

9292
key = match.group('key') if match.group('qkey') is None else match.group('qkey')
9393
val = match.group('val') if match.group('qval') is None else match.group('qval')
@@ -106,9 +106,9 @@ def parse(fp, mapper=dict):
106106
if match.group('vq_end') is None and match.group('qval') is not None:
107107
try:
108108
line += next(fp)
109+
continue
109110
except StopIteration:
110111
raise SyntaxError("vdf.parse: unexpected EOF (open value quote?)")
111-
continue
112112

113113
stack[-1][key] = val
114114

0 commit comments

Comments
 (0)