mirror of
https://github.com/open-webui/computer.git
synced 2026-11-05 01:17:24 +00:00
[GH-ISSUE #267] bug: message is silently lost when sending fails (e.g. network offline) #181
Labels
No labels
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
open-webui/computer#181
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
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 @ebifrier on GitHub (Sep 7, 2026).
Original GitHub issue: https://github.com/open-webui/computer/issues/267
Problem
When sending a chat message fails (network offline, server unreachable, or a non-2xx response), the message silently disappears. The input is cleared, the optimistic user message flashes and is removed, no error is shown, and the text is gone. The only trace is an unhandled
TypeError: Failed to fetchin the console.Steps to reproduce
Actual: the message appears for a moment, then vanishes; the input and attachments are empty; no toast. For a new chat the tab title keeps the first 40 characters of the lost message.
Expected: an error is shown and the message (and attachments) stay in the input so it can be re-sent.
Root cause
In
ChatPanel.sveltesend():inputText = ''andchatInputEl.clearUploads()run beforeapiSendMessageis awaited.catchblock only removes the optimistic message and rethrows. Nothing restores the draft and no toast is shown.ChatInputcallsonsend()without awaiting, so the rethrown error becomes an unhandled rejection and never reaches the user.catchonly logs).Proposed fix
currentMessageId, and reset the new-chat tab label.throw ewithtoast.error(...), matching how compact/fork failures are reported.ApiErrormessages from the server are shown as-is; other failures (network) use a newchat.sendFailedstring.ChatInputgets a smallrestoreUploads()counterpart toclearUploads().Deliberately minimal: no retry button or "failed" marker on the message; happy to adjust if you prefer a different UX.
Verification
Playwright (headless Chromium) against a local build, aborting
POST /api/chatswithinternetdisconnected:Additional context
Implemented on a fork (4 files, +20/-3):
https://github.com/open-webui/computer/compare/main...ebifrier💻fix/keep-message-on-send-failure
Related but different cause: #262 (prompt deleted when moving the window) does not involve sending.
@owui-terminator[bot] commented on GitHub (Sep 7, 2026):
🔍 Related Issues Found
I found some existing issues that might be related. Please check if any of these are duplicates or contain helpful solutions:
🟢 #262 bug: prompt DELETED when moving around window
Related in that both reports describe user-entered prompt text being lost unexpectedly in the chat UI. However, this issue is about text disappearing when moving/resizing the window, not when a send request fails, so the cause is different.
by Classic298
🟣 #50 Gateway connection hangs in OpenWebUI
This is the closest send-path related issue found: it reports a chat request hanging/failing in the gateway path. It is not the same symptom as the message being deleted from the input, but it does concern failure handling in the chat submission flow.
by naqerl
💡 If your issue is a duplicate, please close it and add any additional details to the existing issue instead.
This comment was generated automatically. React with 👍 if helpful, 👎 if not.