Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 48bd2e7

Browse files
committed
Minor patch
1 parent 7ed05f0 commit 48bd2e7

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/core/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1797,7 +1797,7 @@ def getFileItems(filename, commentPrefix='#', unicode_=True, lowercase=False, un
17971797

17981798
checkFile(filename)
17991799

1800-
with codecs.open(filename, 'r', UNICODE_ENCODING) if unicode_ else open(filename, 'r') as f:
1800+
with codecs.open(filename, 'r', UNICODE_ENCODING, errors="ignore") if unicode_ else open(filename, 'r') as f:
18011801
for line in (f.readlines() if unicode_ else f.xreadlines()): # xreadlines doesn't return unicode strings when codec.open() is used
18021802
if commentPrefix:
18031803
if line.find(commentPrefix) != -1:

0 commit comments

Comments
 (0)