[GH-ISSUE #1692] [BUG]: When data parsing fails, the plotting plugin will cause a page error. #1105

Closed
opened 2026-02-22 18:23:08 -05:00 by yindo · 0 comments
Owner

Originally created by @ambitiousCC on GitHub (Jun 15, 2024).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1692

How are you running AnythingLLM?

Docker (local)

What happened?

In anything-llm/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/Chartable/index.jsx:66:

  const chartType = content?.type?.toLowerCase();
  const data =
    typeof content.dataset === "string"
      ? safeJsonParse(content.dataset, null)
      : content.dataset;
  const value = data.length > 0 ? Object.keys(data[0])[1] : "value";
  const title = content?.title;

When the data returns as null, the data.length will cause a JavaScript error, thereby causing the entire page to malfunction.XD

Are there known steps to reproduce?

No response

Originally created by @ambitiousCC on GitHub (Jun 15, 2024). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1692 ### How are you running AnythingLLM? Docker (local) ### What happened? In anything-llm/frontend/src/components/WorkspaceChat/ChatContainer/ChatHistory/Chartable/index.jsx:66: ```js const chartType = content?.type?.toLowerCase(); const data = typeof content.dataset === "string" ? safeJsonParse(content.dataset, null) : content.dataset; const value = data.length > 0 ? Object.keys(data[0])[1] : "value"; const title = content?.title; ``` When the data returns as null, the data.length will cause a JavaScript error, thereby causing the entire page to malfunction.XD ### Are there known steps to reproduce? _No response_
yindo added the possible bug label 2026-02-22 18:23:08 -05:00
yindo closed this issue 2026-02-22 18:23:08 -05:00
yindo changed title from [BUG]: When data parsing fails, the plotting plugin will cause a page error. to [GH-ISSUE #1692] [BUG]: When data parsing fails, the plotting plugin will cause a page error. 2026-06-05 14:39:00 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#1105