You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The SaveLangchain function in PrintUtils.py writes MarkdownVersion to a file. The default encoding for file writing on Windows is cp1252, which doesn't support many Unicode characters and will sometimes cause a crash.
All lines that open files need to be specified as utf-8 like this: with open(ThisLogPathJSON, "w", encoding="utf-8") as f: with open(ThisLogPathMD, "w", encoding="utf-8") as f: with open(f"{self.LogDirPrefix}/Story.md", "w", encoding="utf-8") as f:
The SaveLangchain function in PrintUtils.py writes MarkdownVersion to a file. The default encoding for file writing on Windows is cp1252, which doesn't support many Unicode characters and will sometimes cause a crash.
All lines that open files need to be specified as utf-8 like this:
with open(ThisLogPathJSON, "w", encoding="utf-8") as f:
with open(ThisLogPathMD, "w", encoding="utf-8") as f:
with open(f"{self.LogDirPrefix}/Story.md", "w", encoding="utf-8") as f:
AIStoryWriter/Writer/PrintUtils.py
Lines 41 to 58 in 25d6753
The text was updated successfully, but these errors were encountered: