SimamBehindImage / sitecustomize.py
junaid-simamdigital's picture
Initial What’s Behind the Image prototype
5b86c13 verified
Raw History Blame Contribute Delete
241 Bytes
"""Keep hosted Space logs UTF-8 even when the base image advertises a charmap."""
import sys
for _stream in (sys.stdout, sys.stderr):
if hasattr(_stream, "reconfigure"):
_stream.reconfigure(encoding="utf-8", errors="replace")