Skip to content

Commit

Permalink
fix(logger): set utf-8 encoding
Browse files Browse the repository at this point in the history
  • Loading branch information
CorieW committed Dec 16, 2024
1 parent f516594 commit 8b18211
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/firebase_functions/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@
import typing as _typing
import typing_extensions as _typing_extensions

# If encoding is not 'utf-8', change it to 'utf-8'.
if _sys.stdout.encoding != "utf-8":
_sys.stdout.reconfigure(encoding="utf-8")
if _sys.stderr.encoding != "utf-8":
_sys.stderr.reconfigure(encoding="utf-8")

class LogSeverity(str, _enum.Enum):
"""
Expand Down

0 comments on commit 8b18211

Please sign in to comment.