koala73/worldmonitor · error · Error
Server error: {{status}}
Error message
Server error: {{status}} What it means
UI error in WidgetChatModal.submit: the widget-agent fetch returned a non-OK HTTP status. The response body is parsed as WidgetAgentHealth and passed to reportWidgetEntitlementDesync to detect tester-key/entitlement mismatches before the localized 'Server error' message is thrown with the status code.
Source
Thrown at src/components/WidgetChatModal.ts:317
const res = await fetch(widgetAgentUrl(), {
method: 'POST',
signal: abortController.signal,
headers: reqHeaders,
body,
});
if (!res.ok) {
let payload: WidgetAgentHealth | null = null;
try { payload = await res.json() as WidgetAgentHealth; } catch { /* ignore */ }
reportWidgetEntitlementDesync(
res.status,
payload,
auth.usedTesterKey,
requestBelief,
requestUserId,
);
throw new Error(t('widgets.serverError', { status: res.status }));
}
if (!res.body) {
throw new Error(t('widgets.serverError', { status: res.status }));
}
let resultHtml = '';
let resultTitle = existing?.title ?? 'Custom Widget';
let toolBadgeEl: HTMLElement | null = null;
const statusEl = appendMessage(messagesEl, 'assistant', '');
const radarEl = document.createElement('span');
radarEl.className = 'widget-chat-radar';
setTrustedHtml(radarEl, trustedHtml('<span class="panel-loading-radar"><span class="panel-radar-sweep"></span><span class="panel-radar-dot"></span></span>', "legacy direct innerHTML migration"));
statusEl.appendChild(radarEl);
const reader = res.body.getReader();
const decoder = new TextDecoder();
let buf = '';
View on GitHub (pinned to eeab0a219f)
Solutions
- Retry the request — transient 5xx from the widget agent usually resolve
- Check the status: 401/403 suggests auth or entitlement problems, 429 suggests rate limiting — wait and retry
- If it persists, verify the widget agent deployment is healthy
Defensive patterns
Strategy: retry
When it happens
Trigger: Thrown at src/components/WidgetChatModal.ts:317 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of koala73/worldmonitor@eeab0a219f (2026-08-21).
Data as JSON: /api/errors/526cbf6c56df17a1.
Report an issue: GitHub.