I have searched the existing issues and discussions.
I am using the latest version of Open WebUI.
Installation Method
Docker
Open WebUI Version
v0.6.15
Ollama Version (if applicable)
No response
Operating System
Linux (Docker), can be reproduced in Windows 11 and macOS.
Browser (if applicable)
Both Chrome and Safari
Confirmation
I have read and followed all instructions in README.md.
I am using 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 every relevant configuration, setting, and environment variable used in my setup.
I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
Start with the initial platform/version/OS and dependencies used,
Specify exact install/launch/configure commands,
List URLs visited, user input (incl. example values/emails/passwords if needed),
Describe all options and toggles enabled or changed,
Include any files or environmental changes,
Identify the expected and actual result at each stage,
Ensure any reasonably skilled user can follow and hit the same issue.
Expected Behavior
Not using code interpreter
Actual Behavior
using code interpreter
Steps to Reproduce
Using Gemini model with AI Studio API(both 2.5 Pro and Flash)
Ask a question which may use code interpreter but not enable interpreter , such as what shoud be 114514×1919810?
The code will be run, even if all code related functions(Code Execution and Code Interpreter) are disabled in admin panel.
{"contents":[{"role":"user","parts":[{"text":"what shoud be 114514×1919810?"}]}],"tools":[{"codeExecution":{}}],"safetySettings":[{"category":"HARM_CATEGORY_HARASSMENT","threshold":"OFF"},{"category":"HARM_CATEGORY_HATE_SPEECH","threshold":"OFF"},{"category":"HARM_CATEGORY_SEXUALLY_EXPLICIT","threshold":"OFF"},{"category":"HARM_CATEGORY_DANGEROUS_CONTENT","threshold":"OFF"},{"category":"HARM_CATEGORY_CIVIC_INTEGRITY","threshold":"BLOCK_NONE"}],"generationConfig":{"stopSequences":null,"responseMimeType":null,"responseSchema":null,"candidateCount":1,"temperature":0.7,"topP":0.9,"topK":40,"presencePenalty":null,"frequencyPenalty":null,"responseLogprobs":null,"logprobs":null,"thinkingConfig":{"includeThoughts":true,"thinkingBudget":24576}},"systemInstruction":{"role":"system","parts":[{"text":"User Context:\n\n"}]}}
Response:
{"candidates":[{"content":{"parts":[{"text":"**Calculating a Product**\n\nI've determined I need to calculate the product of 114514 and 1919810. To guarantee accuracy in this multiplication of large numbers, my plan is to utilize the Python interpreter for the computation.\n\n\n","thought":true}],"role":"model"},"index":0},{"content":{"parts":[{"executableCode":{"language":"PYTHON","code":"print(114514 * 1919810)\n"}}],"role":"model"},"index":0},{"content":{"parts":[{"codeExecutionResult":{"outcome":"OUTCOME_OK","output":"219845122340\n"}}],"role":"model"},"index":0},{"content":{"parts":[{"text":"The product of 11"}],"role":"model"},"index":0},{"content":{"parts":[{"text":"4514 and 1919810 is 219"}],"role":"model"},"index":0},{"content":{"parts":[{"text":",845,122,340."}],"role":"model"},"finishReason":"STOP","index":0}],"usageMetadata":{"promptTokenCount":26,"totalTokenCount":228,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"thoughtsTokenCount":46,"candidatesTokenCount":54,"toolUsePromptTokenCount":102,"toolUsePromptTokensDetails":[{"modality":"TEXT","tokenCount":102}]},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4","streamed_data":[{"nonce":"262100","candidates":[{"content":{"parts":[{"text":"**Calculating a Product**\n\nI've determined I need to calculate the product of 114514 and 1919810. To guarantee accuracy in this multiplication of large numbers, my plan is to utilize the Python interpreter for the computation.\n\n\n","thought":true}],"role":"model"},"index":0}],"usageMetadata":{"promptTokenCount":26,"totalTokenCount":72,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"},{"nonce":"0180b7","candidates":[{"content":{"parts":[{"executableCode":{"language":"PYTHON","code":"print(114514 * 1919810)\n"}}],"role":"model"},"index":0}],"usageMetadata":{"promptTokenCount":26,"candidatesTokenCount":17,"totalTokenCount":89,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"},{"nonce":"32e90017","candidates":[{"content":{"parts":[{"codeExecutionResult":{"outcome":"OUTCOME_OK","output":"219845122340\n"}}],"role":"model"},"index":0}],"usageMetadata":{"promptTokenCount":26,"candidatesTokenCount":17,"totalTokenCount":89,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"},{"nonce":"fdc9f3ceea6ce485","candidates":[{"content":{"parts":[{"text":"The product of 11"}],"role":"model"},"index":0}],"usageMetadata":{"promptTokenCount":26,"candidatesTokenCount":23,"totalTokenCount":197,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"toolUsePromptTokenCount":102,"toolUsePromptTokensDetails":[{"modality":"TEXT","tokenCount":102}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"},{"nonce":"ec966e","candidates":[{"content":{"parts":[{"text":"4514 and 1919810 is 219"}],"role":"model"},"index":0}],"usageMetadata":{"promptTokenCount":26,"candidatesTokenCount":41,"totalTokenCount":215,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"toolUsePromptTokenCount":102,"toolUsePromptTokensDetails":[{"modality":"TEXT","tokenCount":102}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"},{"nonce":"9019a41e","candidates":[{"content":{"parts":[{"text":",845,122,340."}],"role":"model"},"finishReason":"STOP","index":0}],"usageMetadata":{"promptTokenCount":26,"candidatesTokenCount":54,"totalTokenCount":228,"promptTokensDetails":[{"modality":"TEXT","tokenCount":26}],"toolUsePromptTokenCount":102,"toolUsePromptTokensDetails":[{"modality":"TEXT","tokenCount":102}],"thoughtsTokenCount":46},"modelVersion":"gemini-2.5-flash","responseId":"flNtaNqpO5r4qtsPg8vusQ4"}]}
Additional Information
No response
Originally created by @t0saki on GitHub (Jul 8, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/15590
### Check Existing Issues
- [x] I have searched the existing issues and discussions.
- [x] I am using the latest version of Open WebUI.
### Installation Method
Docker
### Open WebUI Version
v0.6.15
### Ollama Version (if applicable)
_No response_
### Operating System
Linux (Docker), can be reproduced in Windows 11 and macOS.
### Browser (if applicable)
Both Chrome and Safari
### Confirmation
- [x] I have read and followed all instructions in `README.md`.
- [x] I am using the latest version of **both** Open WebUI and Ollama.
- [x] I have included the browser console logs.
- [x] I have included the Docker container logs.
- [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.**
- [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
- [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps:
- Start with the initial platform/version/OS and dependencies used,
- Specify exact install/launch/configure commands,
- List URLs visited, user input (incl. example values/emails/passwords if needed),
- Describe all options and toggles enabled or changed,
- Include any files or environmental changes,
- Identify the expected and actual result at each stage,
- Ensure any reasonably skilled user can follow and hit the same issue.
### Expected Behavior
Not using code interpreter
### Actual Behavior
using code interpreter
### Steps to Reproduce
1. Using Gemini model with AI Studio API(both 2.5 Pro and Flash)
2. Ask a question which may use code interpreter but not enable interpreter , such as `what shoud be 114514×1919810?`
3. The code will be run, even if all code related functions(Code Execution and Code Interpreter) are disabled in admin panel.
### Logs & Screenshots
Video:
https://github.com/user-attachments/assets/8061caff-4e72-4955-ad0a-454953e70794
Open WebUI logs:
```logs
2025-07-08 17:21:09.692 | INFO | open_webui.routers.openai:get_all_models:391 - get_all_models() - {}
2025-07-08 17:21:10.081 | INFO | httpx._client:_send_single_request:1740 - HTTP Request: POST http://172.17.0.1:37878/api/v1/outlet "HTTP/1.1 200 OK" - {}
2025-07-08 17:21:10.085 | INFO | function_monitor:outlet:195 - usage_monitor: 84b6dbb8-267a-4ae5-955b-e2ff012f7352 Tokens: 12+154 | Cost: $0.0100 | Balance: $99349.3442 | Time: 9.61s | 16.02 T/s - {}
2025-07-08 17:21:10.085 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "POST /api/chat/completed HTTP/1.1" 200 - {}
2025-07-08 17:21:10.297 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "POST /api/v1/chats/fb144716-2c9b-4854-a72c-38c52282aec8 HTTP/1.1" 200 - {}
2025-07-08 17:21:10.570 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 - {}
2025-07-08 17:21:11.037 | INFO | open_webui.routers.openai:get_all_models:391 - get_all_models() - {}
2025-07-08 17:21:11.238 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 - {}
2025-07-08 17:21:11.734 | INFO | open_webui.models.chats:count_chats_by_tag_name_and_user_id:860 - Count of chats for tag 'arithmetic': 2 - {}
2025-07-08 17:21:11.807 | INFO | open_webui.models.chats:count_chats_by_tag_name_and_user_id:860 - Count of chats for tag 'mathematics': 15 - {}
2025-07-08 17:21:11.819 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - 2401:b180:8000:7:f41f:7fed:f41f:7fed:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 - {}
2025-07-08 17:21:12.031 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "GET /api/v1/chats/fb144716-2c9b-4854-a72c-38c52282aec8 HTTP/1.1" 200 - {}
2025-07-08 17:21:12.033 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - 2401:b180:8000:7:f41f:7fed:f41f:7fed:0 - "GET /api/v1/chats/all/tags HTTP/1.1" 200 - {}
2025-07-08 17:21:12.246 | INFO | uvicorn.protocols.http.httptools_impl:send:476 - [SOME_IP]:0 - "GET /api/v1/chats/all/tags HTTP/1.1" 200 - {}
```
Browser console log didn't show anything.
Request:
```json
{
"contents": [
{
"role": "user",
"parts": [
{
"text": "what shoud be 114514×1919810?"
}
]
}
],
"tools": [
{
"codeExecution": {}
}
],
"safetySettings": [
{
"category": "HARM_CATEGORY_HARASSMENT",
"threshold": "OFF"
},
{
"category": "HARM_CATEGORY_HATE_SPEECH",
"threshold": "OFF"
},
{
"category": "HARM_CATEGORY_SEXUALLY_EXPLICIT",
"threshold": "OFF"
},
{
"category": "HARM_CATEGORY_DANGEROUS_CONTENT",
"threshold": "OFF"
},
{
"category": "HARM_CATEGORY_CIVIC_INTEGRITY",
"threshold": "BLOCK_NONE"
}
],
"generationConfig": {
"stopSequences": null,
"responseMimeType": null,
"responseSchema": null,
"candidateCount": 1,
"temperature": 0.7,
"topP": 0.9,
"topK": 40,
"presencePenalty": null,
"frequencyPenalty": null,
"responseLogprobs": null,
"logprobs": null,
"thinkingConfig": {
"includeThoughts": true,
"thinkingBudget": 24576
}
},
"systemInstruction": {
"role": "system",
"parts": [
{
"text": "User Context:\n\n"
}
]
}
}
```
Response:
```json
{
"candidates": [
{
"content": {
"parts": [
{
"text": "**Calculating a Product**\n\nI've determined I need to calculate the product of 114514 and 1919810. To guarantee accuracy in this multiplication of large numbers, my plan is to utilize the Python interpreter for the computation.\n\n\n",
"thought": true
}
],
"role": "model"
},
"index": 0
},
{
"content": {
"parts": [
{
"executableCode": {
"language": "PYTHON",
"code": "print(114514 * 1919810)\n"
}
}
],
"role": "model"
},
"index": 0
},
{
"content": {
"parts": [
{
"codeExecutionResult": {
"outcome": "OUTCOME_OK",
"output": "219845122340\n"
}
}
],
"role": "model"
},
"index": 0
},
{
"content": {
"parts": [
{
"text": "The product of 11"
}
],
"role": "model"
},
"index": 0
},
{
"content": {
"parts": [
{
"text": "4514 and 1919810 is 219"
}
],
"role": "model"
},
"index": 0
},
{
"content": {
"parts": [
{
"text": ",845,122,340."
}
],
"role": "model"
},
"finishReason": "STOP",
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"totalTokenCount": 228,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"thoughtsTokenCount": 46,
"candidatesTokenCount": 54,
"toolUsePromptTokenCount": 102,
"toolUsePromptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 102
}
]
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4",
"streamed_data": [
{
"nonce": "262100",
"candidates": [
{
"content": {
"parts": [
{
"text": "**Calculating a Product**\n\nI've determined I need to calculate the product of 114514 and 1919810. To guarantee accuracy in this multiplication of large numbers, my plan is to utilize the Python interpreter for the computation.\n\n\n",
"thought": true
}
],
"role": "model"
},
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"totalTokenCount": 72,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
},
{
"nonce": "0180b7",
"candidates": [
{
"content": {
"parts": [
{
"executableCode": {
"language": "PYTHON",
"code": "print(114514 * 1919810)\n"
}
}
],
"role": "model"
},
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"candidatesTokenCount": 17,
"totalTokenCount": 89,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
},
{
"nonce": "32e90017",
"candidates": [
{
"content": {
"parts": [
{
"codeExecutionResult": {
"outcome": "OUTCOME_OK",
"output": "219845122340\n"
}
}
],
"role": "model"
},
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"candidatesTokenCount": 17,
"totalTokenCount": 89,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
},
{
"nonce": "fdc9f3ceea6ce485",
"candidates": [
{
"content": {
"parts": [
{
"text": "The product of 11"
}
],
"role": "model"
},
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"candidatesTokenCount": 23,
"totalTokenCount": 197,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"toolUsePromptTokenCount": 102,
"toolUsePromptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 102
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
},
{
"nonce": "ec966e",
"candidates": [
{
"content": {
"parts": [
{
"text": "4514 and 1919810 is 219"
}
],
"role": "model"
},
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"candidatesTokenCount": 41,
"totalTokenCount": 215,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"toolUsePromptTokenCount": 102,
"toolUsePromptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 102
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
},
{
"nonce": "9019a41e",
"candidates": [
{
"content": {
"parts": [
{
"text": ",845,122,340."
}
],
"role": "model"
},
"finishReason": "STOP",
"index": 0
}
],
"usageMetadata": {
"promptTokenCount": 26,
"candidatesTokenCount": 54,
"totalTokenCount": 228,
"promptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 26
}
],
"toolUsePromptTokenCount": 102,
"toolUsePromptTokensDetails": [
{
"modality": "TEXT",
"tokenCount": 102
}
],
"thoughtsTokenCount": 46
},
"modelVersion": "gemini-2.5-flash",
"responseId": "flNtaNqpO5r4qtsPg8vusQ4"
}
]
}
```
### Additional Information
_No response_
GiteaMirror
added the bug label 2026-05-20 22:40:44 -05:00
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 @t0saki on GitHub (Jul 8, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/15590
Check Existing Issues
Installation Method
Docker
Open WebUI Version
v0.6.15
Ollama Version (if applicable)
No response
Operating System
Linux (Docker), can be reproduced in Windows 11 and macOS.
Browser (if applicable)
Both Chrome and Safari
Confirmation
README.md.Expected Behavior
Not using code interpreter
Actual Behavior
using code interpreter
Steps to Reproduce
what shoud be 114514×1919810?Logs & Screenshots
Video:
https://github.com/user-attachments/assets/8061caff-4e72-4955-ad0a-454953e70794
Open WebUI logs:
Browser console log didn't show anything.
Request:
Response:
Additional Information
No response
@t0saki commented on GitHub (Jul 8, 2025):
It may be a function provided by Gemini but not OWUI.