Skip to content

Commit

Permalink
specified encoding to fix windows error
Browse files Browse the repository at this point in the history
  • Loading branch information
grantbuster committed Sep 13, 2023
1 parent 029a254 commit 724d45a
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion tests/test_chunks.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
from elm.chunk import Chunker


with open(os.path.join(TEST_DATA_DIR, 'gpt4.txt'), 'r') as f:
FP_TXT = os.path.join(TEST_DATA_DIR, 'gpt4.txt')
with open(FP_TXT, 'r', encoding='utf8') as f:
TEXT = f.read()


Expand Down
2 changes: 1 addition & 1 deletion tests/test_embed.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
FP_PDF = os.path.join(TEST_DATA_DIR, 'GPT-4.pdf')
FP_TXT = os.path.join(TEST_DATA_DIR, 'gpt4.txt')

with open(FP_TXT, 'r') as f:
with open(FP_TXT, 'r', encoding='utf8') as f:
TEXT = f.read()


Expand Down
2 changes: 1 addition & 1 deletion tests/test_pdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
FP_PDF = os.path.join(TEST_DATA_DIR, 'GPT-4.pdf')
FP_TXT = os.path.join(TEST_DATA_DIR, 'gpt4.txt')

with open(FP_TXT, 'r') as f:
with open(FP_TXT, 'r', encoding='utf8') as f:
TEXT = f.read()


Expand Down
2 changes: 1 addition & 1 deletion tests/test_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
FP_PDF = os.path.join(TEST_DATA_DIR, 'GPT-4.pdf')
FP_TXT = os.path.join(TEST_DATA_DIR, 'gpt4.txt')

with open(FP_TXT, 'r') as f:
with open(FP_TXT, 'r', encoding='utf8') as f:
TEXT = f.read()


Expand Down
2 changes: 1 addition & 1 deletion tests/test_wizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
FP_PDF = os.path.join(TEST_DATA_DIR, 'GPT-4.pdf')
FP_TXT = os.path.join(TEST_DATA_DIR, 'gpt4.txt')

with open(FP_TXT, 'r') as f:
with open(FP_TXT, 'r', encoding='utf8') as f:
TEXT = f.read()


Expand Down

0 comments on commit 724d45a

Please sign in to comment.