Skip to content

Commit

Permalink
Update save.py to use utf-8 instead of None per default
Browse files Browse the repository at this point in the history
I experience issues with the Null on windows. It appears as if when saving HTML, the template is already utf-8 and when writing the files with the system default code page, there are encoding issues.
  • Loading branch information
franzhaas authored Dec 2, 2023
1 parent e1bb266 commit 403ff87
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion altair/utils/save.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def write_file_or_filename(
fp: Union[str, pathlib.PurePath, IO],
content: Union[str, bytes],
mode: str = "w",
encoding: Optional[str] = None,
encoding: Optional[str] = "utf-8",
) -> None:
"""Write content to fp, whether fp is a string, a pathlib Path or a
file-like object"""
Expand Down

0 comments on commit 403ff87

Please sign in to comment.