Skip to content

Conversation

Copy link

Copilot AI commented Dec 5, 2025

Application crashes with "a client-side exception has occurred" when the vLLM backend is unreachable. Three issues cause this:

Changes

  • src/lib/token-counter.ts: getTokenLimit now returns default value (4096) on error instead of throwing unhandled exceptions
  • src/components/chat/chat-topbar.tsx:
    • Validate data.data exists before calling .map() on API error responses
    • Fix toast.error(error as string)toast.error(error instanceof Error ? error.message : String(error)) — Error objects aren't renderable by React
  • src/components/chat/chat-bottombar.tsx: Add .catch() handler for getTokenLimit promise

Before

Before

After

After

Original prompt

This section details on the original issue you should resolve

<issue_title>Application error: a client-side exception has occurred (see the browser console for more information).</issue_title>
<issue_description>Image

Image

Image</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 3 commits December 5, 2025 09:14
Co-authored-by: yoziru <13647408+yoziru@users.noreply.github.com>
Co-authored-by: yoziru <13647408+yoziru@users.noreply.github.com>
Co-authored-by: yoziru <13647408+yoziru@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix application error: client-side exception Fix client-side crash when vLLM server is unavailable Dec 5, 2025
Copilot AI requested a review from yoziru December 5, 2025 09:28
Copilot finished work on behalf of yoziru December 5, 2025 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Application error: a client-side exception has occurred (see the browser console for more information).

2 participants