I have read and followed all the instructions provided in the README.md.
I am on the latest version of both Open WebUI and Ollama.
I have included the browser console logs.
I have included the Docker container logs.
I have provided the exact steps to reproduce the bug in the "Steps to Reproduce" section below.
Expected Behavior:
Setting "GLOBAL_LOG_LEVEL"="CRITICAL" should make the logging pipeline to only log CRITICAL events
Actual Behavior:
Setting the above variable makes no difference, logs is still being logged in INFO mode, as evident from the console logs below.
Description
Bug Summary:
Env var GLOBAL_LOG_LEVEL="" is not respected when logging to console
Reproduction Details
Steps to Reproduce:
Run the openwebui (ghcr.io/open-webui/open-webui:0.4.8) with env var GLOBAL_LOG_LEVEL set to CRITICAL
Docker Container Logs:
v0.4.8 - building the best open-source AI user interface.
https://github.com/open-webui/open-webui
INFO: Started server process [1]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:8080 (Press CTRL+C to quit)
INFO: 10.20.10.120:0 - "GET /ws/socket.io/?EIO=4&transport=polling&t=PF8uuTj HTTP/1.1" 200 OK
INFO: 10.20.10.120:0 - "POST /ws/socket.io/?EIO=4&transport=polling&t= HTTP/1.1" 200 OK
INFO: 10.20.10.120:0 - "GET /ws/socket.io/?EIO=4&transport=polling&t= HTTP/1.1" 200 OK
INFO: ('10.20.10.120', 0) - "WebSocket /ws/socket.io/?EIO=4&transport=websocket&sid=" [accepted]
INFO: connection open
Originally created by @nebula-it on GitHub (Dec 15, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/7859
# Bug Report
---
## Installation Method
Helm Chart:
```
dependencies:
- name: open-webui
version: "4.1.0"
repository: https://open-webui.github.io/helm-charts
```
## Environment
- **Open WebUI Version:** v0.4.8
- **Ollama:** v0.4.6
**Confirmation:**
- [x] I have read and followed all the instructions provided in the README.md.
- [x] I am on the latest version of both Open WebUI and Ollama.
- [ ] I have included the browser console logs.
- [x] I have included the Docker container logs.
- [ ] I have provided the exact steps to reproduce the bug in the "Steps to Reproduce" section below.
## Expected Behavior:
Setting `"GLOBAL_LOG_LEVEL"="CRITICAL"` should make the logging pipeline to only log CRITICAL events
## Actual Behavior:
Setting the above variable makes no difference, logs is still being logged in `INFO` mode, as evident from the console logs below.
## Description
**Bug Summary:**
Env var GLOBAL_LOG_LEVEL="" is not respected when logging to console
## Reproduction Details
**Steps to Reproduce:**
* Run the openwebui (ghcr.io/open-webui/open-webui:0.4.8) with env var `GLOBAL_LOG_LEVEL` set to `CRITICAL`
**Docker Container Logs:**
```
v0.4.8 - building the best open-source AI user interface.
https://github.com/open-webui/open-webui
INFO: Started server process [1]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:8080 (Press CTRL+C to quit)
INFO: 10.20.10.120:0 - "GET /ws/socket.io/?EIO=4&transport=polling&t=PF8uuTj HTTP/1.1" 200 OK
INFO: 10.20.10.120:0 - "POST /ws/socket.io/?EIO=4&transport=polling&t= HTTP/1.1" 200 OK
INFO: 10.20.10.120:0 - "GET /ws/socket.io/?EIO=4&transport=polling&t= HTTP/1.1" 200 OK
INFO: ('10.20.10.120', 0) - "WebSocket /ws/socket.io/?EIO=4&transport=websocket&sid=" [accepted]
INFO: connection open
```
Yeah that seems to have made some change, now the logs starting wtih [open_webui.env] dont show up but the access logs for http server are still there and they all have a prefix INFO so I assume some components are not being affected by it.
<!-- gh-comment-id:2546993484 -->
@nebula-it commented on GitHub (Dec 16, 2024):
Yeah that seems to have made some change, now the logs starting wtih `[open_webui.env]` dont show up but the access logs for http server are still there and they all have a prefix `INFO` so I assume some components are not being affected by it.
INFO: 127.0.0.1:52458 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 OK
is generated by Uvicorn's access log, which records each HTTP request received by the server.
Temporary Fix for the Issue
This is a temporary fix until the author updates the variables in the code. Follow these steps to resolve the issue:
Steps
For Windows:
Navigate to: C:\Users\%**YOUR USER NAME**%\AppData\Local\Programs\Python\Python311\Lib\site-packages\open_webui
For Other OS or Virtual Environments:
Locate the site-packages directory within your Python environment. If you're using a virtual environment (venv), it will typically be in: path_to_venv/lib/pythonX.X/site-packages/open_webui
Locate the __init__.py script in the directory.
Refer to the images below to see what needs to be added and where.
What to Add and Where
Result
You can use other log levels as you wish, or refer to the environment variable here.
<!-- gh-comment-id:2561197711 -->
@Adhithya03 commented on GitHub (Dec 24, 2024):
@nebula-it @twhite-gh
The log message you're seeing:
```
INFO: 127.0.0.1:52458 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 OK
```
is generated by Uvicorn's **access log**, which records each HTTP request received by the server.
**Temporary Fix for the Issue**
This is a temporary fix until the author updates the variables in the code. Follow these steps to resolve the issue:
### Steps
1. **For Windows**:
Navigate to:
`C:\Users\%**YOUR USER NAME**%\AppData\Local\Programs\Python\Python311\Lib\site-packages\open_webui`
2. **For Other OS or Virtual Environments**:
Locate the `site-packages` directory within your Python environment. If you're using a virtual environment (venv), it will typically be in:
`path_to_venv/lib/pythonX.X/site-packages/open_webui`
3. Locate the `__init__.py` script in the directory.
4. Refer to the images below to see what needs to be added and where.
### What to Add and Where

### Result

You can use other log levels as you wish, or refer to the environment variable here.
Hey @Adhithya03
Thank you for digging that one up. I've updated that file using sed -i 's|^\( uvicorn\.run\(.*\)\))|\1, log_level="critical")|' __init__.py if anyone needs it.
@Adhithya03 any chance you can do a PR to update this value automatically from env var? 🙏
<!-- gh-comment-id:2561424891 -->
@nebula-it commented on GitHub (Dec 24, 2024):
Hey @Adhithya03
Thank you for digging that one up. I've updated that file using `sed -i 's|^\( uvicorn\.run\(.*\)\))|\1, log_level="critical")|' __init__.py` if anyone needs it.
@Adhithya03 any chance you can do a PR to update this value automatically from env var? 🙏
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Originally created by @nebula-it on GitHub (Dec 15, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/7859
Bug Report
Installation Method
Helm Chart:
Environment
Confirmation:
Expected Behavior:
Setting
"GLOBAL_LOG_LEVEL"="CRITICAL"should make the logging pipeline to only log CRITICAL eventsActual Behavior:
Setting the above variable makes no difference, logs is still being logged in
INFOmode, as evident from the console logs below.Description
Bug Summary:
Env var GLOBAL_LOG_LEVEL="" is not respected when logging to console
Reproduction Details
Steps to Reproduce:
GLOBAL_LOG_LEVELset toCRITICALDocker Container Logs:
@twhite-gh commented on GitHub (Dec 16, 2024):
same as you. not working.
@TheMasterFX commented on GitHub (Dec 16, 2024):
Try without quotes
GLOBAL_LOG_LEVEL=CRITICAL@nebula-it commented on GitHub (Dec 16, 2024):
Yeah that seems to have made some change, now the logs starting wtih
[open_webui.env]dont show up but the access logs for http server are still there and they all have a prefixINFOso I assume some components are not being affected by it.@Adhithya03 commented on GitHub (Dec 24, 2024):
@nebula-it @twhite-gh
The log message you're seeing:
is generated by Uvicorn's access log, which records each HTTP request received by the server.
Temporary Fix for the Issue
This is a temporary fix until the author updates the variables in the code. Follow these steps to resolve the issue:
Steps
For Windows:
Navigate to:
C:\Users\%**YOUR USER NAME**%\AppData\Local\Programs\Python\Python311\Lib\site-packages\open_webuiFor Other OS or Virtual Environments:
Locate the
site-packagesdirectory within your Python environment. If you're using a virtual environment (venv), it will typically be in:path_to_venv/lib/pythonX.X/site-packages/open_webuiLocate the
__init__.pyscript in the directory.Refer to the images below to see what needs to be added and where.
What to Add and Where
Result
You can use other log levels as you wish, or refer to the environment variable here.
@nebula-it commented on GitHub (Dec 24, 2024):
Hey @Adhithya03
Thank you for digging that one up. I've updated that file using
sed -i 's|^\( uvicorn\.run\(.*\)\))|\1, log_level="critical")|' __init__.pyif anyone needs it.@Adhithya03 any chance you can do a PR to update this value automatically from env var? 🙏
@Adhithya03 commented on GitHub (Dec 25, 2024):
Hello @nebula-it,
I've just opened a PR #8053.
@nebula-it commented on GitHub (Dec 25, 2024):
Perfect, thanks much bud.
With that, I'll close this issue.