fix: CTP 需 zh_CN.GB18030 中文 locale 而非仅 UTF-8
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9,7 +9,7 @@ import sys
|
||||
BASE = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
||||
sys.path.insert(0, BASE)
|
||||
|
||||
from locale_fix import ensure_process_locale
|
||||
from locale_fix import ensure_process_locale, missing_ctp_locales
|
||||
|
||||
ensure_process_locale()
|
||||
|
||||
@@ -40,6 +40,9 @@ def main() -> int:
|
||||
|
||||
print("=== SimNow 配置 ===")
|
||||
print(f"locale = {ensure_process_locale()}")
|
||||
missing = missing_ctp_locales()
|
||||
if missing:
|
||||
print(f"警告: 缺少 CTP 所需 locale: {', '.join(missing)}")
|
||||
print(f"SIMNOW_USER = {user or '(未设置)'}")
|
||||
print(f"SIMNOW_PASSWORD = {'*' * 8 if os.getenv('SIMNOW_PASSWORD') else '(未设置)'}")
|
||||
print(f"SIMNOW_TD = {td}")
|
||||
|
||||
Reference in New Issue
Block a user