Skip to content

[Bug]: Exception during startup for CN users on Windows on python 3.13 #1331

Description

@yamatazen

What happened?

This happened during startup. OneTrainer seems to work fine though.

What did you expect would happen?

Startup without exceptions

Relevant log output

activating venv C:\Users\yamat\Desktop\OneTrainer\venv
Using Python "C:\Users\yamat\Desktop\OneTrainer\venv\Scripts\python.exe" -X utf8
HF_HUB_DISABLE_XET=1

NOTE: Xet disabled, to enable it set as 0 before launch
Checking Python version...
Python 3.13.12

Starting UI...
Exception in thread Thread-2 (_readerthread):
Traceback (most recent call last):
  File "C:\Users\yamat\AppData\Local\Programs\Python\Python313\Lib\threading.py", line 1044, in _bootstrap_inner
    self.run()
    ~~~~~~~~^^
  File "C:\Users\yamat\AppData\Local\Programs\Python\Python313\Lib\threading.py", line 995, in run
    self._target(*self._args, **self._kwargs)
    ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\yamat\AppData\Local\Programs\Python\Python313\Lib\subprocess.py", line 1615, in _readerthread
    buffer.append(fh.read())
                  ~~~~~~~^^
  File "<frozen codecs>", line 325, in decode
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xa4 in position 7: invalid start byte

Generate and upload debug_report.log

=== System Information ===
OS: Windows 11
Version: 10.0.26200

=== Hardware Information ===
CPU: 12th Gen Intel(R) Core(TM) i7-12700F (Cores: 12)
Total RAM: 15.76 GB

=== GPU Information ===
NVIDIA GPU (Index 0): NVIDIA GeForce RTX 3060 [NVIDIA]
    Driver version: 591.86
    Power Limit: 170.00 W

=== Python Environment ===
Global Python Version: 3.13.12
Python Executable Path: C:\Users\anonymous\Desktop\OneTrainer\venv\Scripts\python.exe
PyTorch Info: torch==2.9.1+cu128
pip freeze output:
    absl-py==2.4.0
    accelerate==1.12.0
    adv_optm==2.2.3
    aiodns==4.0.0
    aiohappyeyeballs==2.6.1
    aiohttp==3.13.3
    aiohttp-retry==2.9.1
    aiosignal==1.4.0
    annotated-doc==0.0.4
    annotated-types==0.7.0
    antlr4-python3-runtime==4.9.3
    anyio==4.12.1
    attrs==25.4.0
    av==16.1.0
    backoff==2.2.1
    backports.zstd==1.3.0
    bcrypt==5.0.0
    bitsandbytes==0.49.1
    boto3==1.42.51
    botocore==1.42.51
    brotli==1.2.0
    certifi==2026.1.4
    cffi==2.0.0
    charset-normalizer==3.4.4
    click==8.2.1
    cloudpickle==3.1.2
    colorama==0.4.6
    coloredlogs==15.0.1
    contourpy==1.3.3
    cryptography==45.0.7
    customtkinter==5.2.2
    cycler==0.12.1
    dadaptation==3.2
    darkdetect==0.8.0
    decorator==5.2.1
    deepdiff==8.6.1
    Deprecated==1.3.1
    -e git+https://github.com/huggingface/diffusers.git@6a1904eb065ba4daad6bfe784cc3064852755acf#egg=diffusers
    dnspython==2.8.0
    email-validator==2.3.0
    fabric==3.2.2
    fastapi==0.129.0
    fastapi-cli==0.0.23
    fastapi-cloud-cli==0.13.0
    fastar==0.8.0
    filelock==3.24.2
    flatbuffers==25.12.19
    fonttools==4.61.1
    frozenlist==1.8.0
    fsspec==2026.2.0
    ftfy==6.3.1
    gguf==0.17.1
    grpcio==1.78.0
    h11==0.16.0
    httpcore==1.0.9
    httptools==0.7.1
    httpx==0.28.1
    huggingface-hub==0.34.4
    humanfriendly==10.0
    idna==3.11
    imagesize==1.4.1
    importlib_metadata==8.7.1
    inquirerpy==0.3.4
    invisible-watermark==0.2.0
    invoke==2.2.1
    itsdangerous==2.2.0
    Jinja2==3.1.6
    jmespath==1.1.0
    kiwisolver==1.4.9
    lightning-utilities==0.15.2
    lion-pytorch==0.2.3
    Markdown==3.10.2
    markdown-it-py==4.0.0
    MarkupSafe==3.0.3
    matplotlib==3.10.3
    mdurl==0.1.2
    -e git+https://github.com/Nerogar/mgds.git@a0c84a3de995590b5a162e5249d36365d18864a9#egg=mgds
    mpmath==1.3.0
    multidict==6.7.1
    -e git+https://github.com/KellerJordan/Muon.git@f90a42b28e00b8d9d2d05865fe90d9f39abcbcbd#egg=muon_optimizer
    networkx==3.6.1
    numpy==2.2.6
    nvidia-ml-py==13.590.48
    omegaconf==2.3.0
    onnxruntime-gpu==1.23.2
    open_clip_torch==2.32.0
    opencv-python==4.11.0.86
    orderly-set==5.5.0
    orjson==3.11.7
    packaging==26.0
    paramiko==4.0.0
    parse==1.20.2
    pfzy==0.3.4
    pillow==11.3.0
    platformdirs==4.9.2
    pooch==1.8.2
    prettytable==3.17.0
    prodigy-plus-schedule-free==2.0.1
    prodigyopt==1.1.2
    prompt_toolkit==3.0.52
    propcache==0.4.1
    protobuf==6.33.5
    psutil==7.0.0
    py-cpuinfo==9.0.0
    pycares==5.0.1
    pycparser==3.0
    pydantic==2.12.5
    pydantic-extra-types==2.11.0
    pydantic-settings==2.13.0
    pydantic_core==2.41.5
    Pygments==2.19.2
    PyNaCl==1.6.2
    pyparsing==3.3.2
    pyreadline3==3.5.4
    python-dateutil==2.9.0.post0
    python-dotenv==1.2.1
    python-multipart==0.0.22
    pytorch-lightning==2.6.1
    pytorch_optimizer==3.6.0
    PyWavelets==1.9.0
    PyYAML==6.0.2
    regex==2026.1.15
    requests==2.32.5
    rich==14.3.2
    rich-toolkit==0.19.4
    rignore==0.7.6
    runpod==1.7.10
    s3transfer==0.16.0
    safetensors==0.7.0
    scalene==1.5.51
    scenedetect==0.6.7.1
    schedulefree==1.4.1
    scipy==1.15.3
    sentencepiece==0.2.1
    sentry-sdk==2.53.0
    setuptools==81.0.0
    shellingham==1.5.4
    six==1.17.0
    starlette==0.52.1
    sympy==1.14.0
    tensorboard==2.20.0
    tensorboard-data-server==0.7.2
    timm==1.0.24
    tokenizers==0.22.2
    tomli==2.4.0
    tomlkit==0.14.0
    torch==2.9.1+cu128
    torchmetrics==1.8.2
    torchvision==0.24.1+cu128
    tqdm==4.67.1
    tqdm-loggable==0.3
    transformers==4.57.6
    triton-windows==3.5.1.post24
    typer==0.24.0
    typing-inspection==0.4.2
    typing_extensions==4.15.0
    ujson==5.11.0
    urllib3==2.6.3
    uvicorn==0.41.0
    watchdog==6.0.0
    watchfiles==1.1.1
    wcwidth==0.6.0
    websockets==16.0
    Werkzeug==3.1.5
    wheel==0.46.3
    wrapt==2.1.1
    yarl==1.22.0
    yt-dlp==2026.2.4
    zipp==3.23.0

=== Git Information ===
Repo: Nerogar/OneTrainer
Branch: master
Commit: 2f441811a204deb0898fce4b1d5a4af605380bec
No deleted, unmerged, or modified files relative to origin/master.

=== Network Connectivity ===
PyPI (https://pypi.org/): Failure: expected string or bytes-like object, got 'NoneType'
HuggingFace (https://huggingface.co): Failure: expected string or bytes-like object, got 'NoneType'
Google (https://www.google.com): Failure: expected string or bytes-like object, got 'NoneType'

=== Intel Microcode Information ===
CPU is not detected as 13th or 14th Gen Intel - microcode info not applicable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingwaitingwaiting for something / cannot fix currently

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions