mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-06 10:58:17 -05:00
[GH-ISSUE #21377] issue: [object Object] error when changing model access control in Admin Panel (v0.8.0) #19459
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ahgray on GitHub (Feb 13, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/21377
Check Existing Issues
Installation Method
Docker
Open WebUI Version
v0.8.0
Ollama Version (if applicable)
n/a
Operating System
Ubuntu 22.04 w/Docker
Browser (if applicable)
Firefox 147 also reproduced on Chrome
Confirmation
README.md.Expected Behavior
The model's access control should update successfully and display a success toast notification.
Actual Behavior
An [object Object] error toast appears. The access control change does not persist — refreshing the page shows the model retains its original access control setting.
Steps to Reproduce
Log in as an admin user.
Navigate to Admin Panel → Settings → Models.
Click the edit (pencil) icon on any model.
Change the Access Control dropdown from Private to Public (or any other change).
Observe the [object Object] error toast in the top-right corner.
Logs & Screenshots
Browser Console Output
The browser Network tab reveals the root cause:
XHRPOST http://10.0.7.114:3000/api/v1/models/model/access/update
[HTTP/1.1 404 Not Found 6ms]
Status: 404 Not Found
The URL contains the literal string model where the actual model ID should be (e.g., it should be /api/v1/models/gpt-4o/access/update or /api/v1/models/llama3:latest/access/update). The frontend component is passing a hardcoded or incorrectly-bound variable to the API call instead of the selected model's actual ID.
The 404 JSON response ({"detail": "Not Found"}) is then displayed as [object Object] in the toast, likely because the error handler calls something like toast.error(error) on the response object rather than extracting the string (e.g., toast.error(error.detail)).
Full console output:
SES Removing unpermitted intrinsics lockdown-install.js:1:203117
Removing intrinsics.%MapPrototype%.getOrInsert lockdown-install.js:1:202962
Removing intrinsics.%MapPrototype%.getOrInsertComputed lockdown-install.js:1:202962
Removing intrinsics.%WeakMapPrototype%.getOrInsert lockdown-install.js:1:202962
Removing intrinsics.%WeakMapPrototype%.getOrInsertComputed lockdown-install.js:1:202962
Removing intrinsics.%DatePrototype%.toTemporalInstant lockdown-install.js:1:202962
XHRPOST
http://192.168.1.50:3000/api/v1/models/model/access/update
[HTTP/1.1 404 Not Found 6ms]
(The SES/lockdown messages are unrelated browser extension output.)
Additional Information
After upgrading to v0.8.0, changing a model's access control (e.g., from Private to Public) via the Admin Panel produces an [object Object] error toast notification. The new access control UI introduced in #21277 sends the literal string "model" as the model ID in the API request instead of the actual model identifier, resulting in a 404 response that is displayed as [object Object] in the toast.
@Classic298 commented on GitHub (Feb 13, 2026):
cannot reproduce. do you have any error logs relating to the access control migration?
@ahgray commented on GitHub (Feb 13, 2026):
nothing showing in the docker logs just the post request.
uvicorn.protocols.http.httptools_impl:send:483 - 10.0.7.56:62911 - "POST /api/v1/models/model/access/update HTTP/1.1" 404
Just tried it in Chrome with dev console and get the following. Not sure if this helps. Happy to provide additional info. Not sure whats needed.
index.ts:287 POST http://10.0.7.114:3000/api/v1/models/model/access/update 404 (Not Found)
window.fetch @ fetcher.js:76
g @ index.ts:287
onChange @ ModelEditor.svelte:349
me @ AccessControl.svelte:192
ot @ AccessControl.svelte:211
(anonymous) @ AccessControl.svelte:474
(anonymous) @ events.js:61
Mt @ shared.js:44
s @ events.js:60
handleMouseUp_ @ unknown
@Classic298 commented on GitHub (Feb 13, 2026):
hmmm
@ahgray commented on GitHub (Feb 13, 2026):
Ok this is way over my head but I've been troubleshooting this with Claude 4.6 and I've been able to create a workspace model and update its permission and then manually change the task model with a curl command. So I think Claude might be onto something. Anyway below is the comment it suggested I provide. Like I said I'm way out of my league here so if this is just AI slop take it with a tablespoon of salt lol.
v0.8.0 Access Control Regression: Two Bugs from PR #21277 Migration
I've done extensive debugging on the access control issues introduced by the PR #21277 refactor and found two distinct bugs. Both stem from incomplete migration between the old
access_controlJSON column and the newaccess_granttable system.Environment
ghcr.io/open-webui/open-webui:cuda)b0ecd5d7101000fc1907043df386358b35ab4475efccec591bf7ba1805aabb81access_controlcolumn fully removed frommodeltable,access_granttable present and functional)Bug 1: Access Control UI Renders for Base/Connection Models → 404 →
[object Object]Steps to reproduce:
[object Object]toast errorRoot cause:
The Admin Panel renders the
AccessControlcomponent for all models, including base/connection models that have no corresponding row in themodeldatabase table. When the dropdown is changed, the frontend calls:The backend handler at
routers/models.py:507-540callsModels.get_model_by_id(), which returnsNonefor base models (they don't exist in themodeltable), resulting in a 404. The frontend then displays the error object as[object Object]instead of a human-readable message.Expected behavior: Either hide the access control UI for non-workspace models, or auto-create a
modeltable row when access is modified on a base model.Bug 2: Task Model Selector Rejects All Models — Legacy
access_controlCheck on Removed FieldSteps to reproduce:
access_grantRoot cause:
src/lib/components/admin/Settings/Interface.sveltelines 155 and 190:PR #21277 removed the
access_controlcolumn from the database and the API no longer returns this field on model objects. Somodel.access_controlis alwaysundefined, and in JavaScript:Every model fails this check. The validation is dead code that now blocks all task model selection from the UI.
Confirmed: The database has no
access_controlcolumn. Theaccess_granttable works correctly — I have a workspace model with a valid public grant:Yet the UI still rejects it because it checks a field that no longer exists.
Workaround: Set the task model via API, bypassing frontend validation:
This works — the backend accepts it without issue.
Suggested Fixes
Bug 1:
modeltable rowmodeltable row when access is first configured on a base modelBug 2:
access_control !== nullcheck entirely (admins should be able to select any model as a task model — see also #14172)access_granttable to check actual public statusBoth bugs indicate the PR #21277 migration left some frontend code pointing at the old
access_controlfield. A grep foraccess_controlacross the frontend source may reveal other similar references that need updating.Related
id()leak bug in model access control (v0.6.36, similar pattern)@tjbck commented on GitHub (Feb 13, 2026):
Should be addressed in dev!
@ahgray commented on GitHub (Feb 13, 2026):
Awesome. Hopefully the information was helpful.