mirror of
https://github.com/Benexl/FastAnime.git
synced 2026-01-01 23:39:54 -08:00
fix(cli): ensure UTF-8 encoding on Windows platforms
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
from .cli import cli as run_cli
|
||||
import sys
|
||||
import os
|
||||
|
||||
if sys.platform.startswith("win"):
|
||||
os.environ.setdefault("PYTHONUTF8", "1")
|
||||
try:
|
||||
sys.stdout.reconfigure(encoding="utf-8")
|
||||
sys.stderr.reconfigure(encoding="utf-8")
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
__all__ = ["run_cli"]
|
||||
|
||||
Reference in New Issue
Block a user