Skip to content

Commit 6d18b14

Browse files
committed
disable parse recover
1 parent 260c788 commit 6d18b14

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ def parse_and_remove(f, path):
257257
snippet from python cookbook, for parsing large xml file
258258
"""
259259
path_parts = path.split('/')
260-
doc = iterparse(f, ('start', 'end'), recover=True, encoding='utf-8')
260+
doc = iterparse(f, ('start', 'end'), recover=False, encoding='utf-8', huge_tree=True)
261261
# Skip the root element
262262
next(doc)
263263
tag_stack = []

0 commit comments

Comments
 (0)