Installation Fails Due to UTF-8 Encoding Error and Application Does Not Automatically Launch WebView After Server Start #23

Closed
opened 2026-02-15 20:16:50 -05:00 by yindo · 2 comments
Owner

Originally created by @AmesianX on GitHub (Apr 3, 2025).

UTF-8 Error

When the installation starts, the server crashes due to a UTF-8 encoding error. So I manually modified the following file to make the server run properly without any errors.

Log

Installed Python Version: Python 3.11.11
"C:\Users\user\AppData\Roaming\Open WebUI\python\Scripts\activate.bat" && uvicorn open_webui.main:app --host "127.0.0.1" --forwarded-allow-ips '*' --port 8081
Starting Open-WebUI server...
Server started with PID: 23932
INFO [alembic.runtime.migration] Context impl SQLiteImpl.
INFO [alembic.runtime.migration] Will assume non-transactional DDL.
INFO [open_webui.env] 'DEFAULT_LOCALE' loaded from the latest database entry
INFO [open_webui.env] 'DEFAULT_PROMPT_SUGGESTIONS' loaded from the latest database entry
WARNI [open_webui.env]

WARNING: CORS_ALLOW_ORIGIN IS SET TO '*' - NOT RECOMMENDED FOR PRODUCTION DEPLOYMENTS.
INFO [open_webui.env] Embedding model set: sentence-transformers/all-MiniLM-L6-v2
WARNI [langchain_community.utils.user_agent] USER_AGENT environment variable not set, consider setting it to identify your requests.
C:\Users\user\AppData\Roaming\Open WebUI\python\Lib\site-packages\open_webui
C:\Users\user\AppData\Roaming\Open WebUI\python\Lib\site-packages
C:\Users\user\AppData\Roaming\Open WebUI\python\Lib

ERROR UTF-8 encoding error

██████╗ ██████╗ ███████╗███╗ ██╗ ██╗ ██╗███████╗██████╗ ██╗ ██╗██╗
██╔═══██╗██╔══██╗██╔════╝████╗ ██║ ██║ ██║██╔════╝██╔══██╗██║ ██║██║
██║ ██║██████╔╝█████╗ ██╔██╗ ██║ ██║ █╗ ██║█████╗ ██████╔╝██║ ██║██║
██║ ██║██╔═══╝ ██╔══╝ ██║╚██╗██║ ██║███╗██║██╔══╝ ██╔══██╗██║ ██║██║
╚██████╔╝██║ ███████╗██║ ╚████║ ╚███╔███╔╝███████╗██████╔╝╚██████╔╝██║
╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═══╝ ╚══╝╚══╝ ╚══════╝╚═════╝ ╚═════╝ ╚═╝

v0.6.0 - building the best open-source AI user interface.

https://github.com/open-webui/open-webui
Fetching 30 files: 0%| | 0/30 [00:00<?, ?it/s]
Fetching 30 files: 100%|##########| 30/30 [00:00<00:00, 39983.83it/s]
INFO: Started server process [32780]
INFO: Waiting for application startup.
2025-04-03 18:35:38.014 | INFO | open_webui.utils.logger:start_logger:140 - GLOBAL_LOG_LEVEL: INFO - {}

My Ugly SOLUTION [c:\Users\xxx\AppData\Roaming\Open WebUI\python\Lib\site-packages\open_webui\main.py]

import asyncio
import inspect
import json
import logging
import mimetypes
import os
import shutil
import sys
import time
import random

# start ugly solution
import io
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')
# end

from contextlib import asynccontextmanager
from urllib.parse import urlencode, parse_qs, urlparse
from pydantic import BaseModel
from sqlalchemy import text

ISSUE

However, after the server starts, I believe it should automatically open a WebView (or similar) that connects to the local server.
But instead, it just stays running without doing anything.
If I manually open a browser and go to localhost:8080, everything works fine.
But if I understand the purpose of this desktop application correctly, shouldn’t it open the interface inside the application window itself after installation, just like Claude Desktop or LM Studio?

Originally created by @AmesianX on GitHub (Apr 3, 2025). ## UTF-8 Error When the installation starts, the server crashes due to a UTF-8 encoding error. So I manually modified the following file to make the server run properly without any errors. ## Log Installed Python Version: Python 3.11.11 "C:\Users\user\AppData\Roaming\Open WebUI\python\Scripts\activate.bat" && uvicorn open_webui.main:app --host "127.0.0.1" --forwarded-allow-ips '*' --port 8081 Starting Open-WebUI server... Server started with PID: 23932 INFO [alembic.runtime.migration] Context impl SQLiteImpl. INFO [alembic.runtime.migration] Will assume non-transactional DDL. INFO [open_webui.env] 'DEFAULT_LOCALE' loaded from the latest database entry INFO [open_webui.env] 'DEFAULT_PROMPT_SUGGESTIONS' loaded from the latest database entry WARNI [open_webui.env] WARNING: CORS_ALLOW_ORIGIN IS SET TO '*' - NOT RECOMMENDED FOR PRODUCTION DEPLOYMENTS. INFO [open_webui.env] Embedding model set: sentence-transformers/all-MiniLM-L6-v2 WARNI [langchain_community.utils.user_agent] USER_AGENT environment variable not set, consider setting it to identify your requests. C:\Users\user\AppData\Roaming\Open WebUI\python\Lib\site-packages\open_webui C:\Users\user\AppData\Roaming\Open WebUI\python\Lib\site-packages C:\Users\user\AppData\Roaming\Open WebUI\python\Lib ## ERROR UTF-8 encoding error ██████╗ ██████╗ ███████╗███╗ ██╗ ██╗ ██╗███████╗██████╗ ██╗ ██╗██╗ ██╔═══██╗██╔══██╗██╔════╝████╗ ██║ ██║ ██║██╔════╝██╔══██╗██║ ██║██║ ██║ ██║██████╔╝█████╗ ██╔██╗ ██║ ██║ █╗ ██║█████╗ ██████╔╝██║ ██║██║ ██║ ██║██╔═══╝ ██╔══╝ ██║╚██╗██║ ██║███╗██║██╔══╝ ██╔══██╗██║ ██║██║ ╚██████╔╝██║ ███████╗██║ ╚████║ ╚███╔███╔╝███████╗██████╔╝╚██████╔╝██║ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═══╝ ╚══╝╚══╝ ╚══════╝╚═════╝ ╚═════╝ ╚═╝ v0.6.0 - building the best open-source AI user interface. https://github.com/open-webui/open-webui Fetching 30 files: 0%| | 0/30 [00:00<?, ?it/s] Fetching 30 files: 100%|##########| 30/30 [00:00<00:00, 39983.83it/s] INFO: Started server process [32780] INFO: Waiting for application startup. 2025-04-03 18:35:38.014 | INFO | open_webui.utils.logger:start_logger:140 - GLOBAL_LOG_LEVEL: INFO - {} ### My Ugly SOLUTION [c:\Users\xxx\AppData\Roaming\Open WebUI\python\Lib\site-packages\open_webui\main.py] import asyncio import inspect import json import logging import mimetypes import os import shutil import sys import time import random \# start ugly solution import io sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8') \# end from contextlib import asynccontextmanager from urllib.parse import urlencode, parse_qs, urlparse from pydantic import BaseModel from sqlalchemy import text ## ISSUE However, after the server starts, I believe it should automatically open a WebView (or similar) that connects to the local server. But instead, it just stays running without doing anything. If I manually open a browser and go to localhost:8080, everything works fine. But if I understand the purpose of this desktop application correctly, shouldn’t it open the interface inside the application window itself after installation, just like Claude Desktop or LM Studio?
yindo closed this issue 2026-02-15 20:16:50 -05:00
Author
Owner

@mazenhassan9 commented on GitHub (Apr 12, 2025):

I have the same error, did you find any way to fix this issue?

@mazenhassan9 commented on GitHub (Apr 12, 2025): I have the same error, did you find any way to fix this issue?
Author
Owner

@tjbck commented on GitHub (Jul 29, 2025):

Addressed in main!

@tjbck commented on GitHub (Jul 29, 2025): Addressed in main!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: open-webui/desktop#23