Skip to content

Harden chart node data, rendering, and lifecycle#9

Merged
dovvnloading merged 1 commit into
mainfrom
agent/chart-node-repair
Jul 15, 2026
Merged

Harden chart node data, rendering, and lifecycle#9
dovvnloading merged 1 commit into
mainfrom
agent/chart-node-repair

Conversation

@dovvnloading

Copy link
Copy Markdown
Owner

Summary

This PR repairs chart/graph-node data integrity, rendering behavior, graph lifecycle handling, and persistence.

What changed

  • Added one canonical chart-data validator for all chart types.
  • Rejects malformed containers, non-finite values, oversized payloads, invalid Sankey cycles, and mismatched series.
  • Aggregates duplicate Sankey edges.
  • Added responsive categorical tick selection and pie-slice grouping.
  • Added render caching, font/theme-aware invalidation, resize bounds, and safer export cleanup.
  • Added explicit chart provenance connections and recursive cleanup.
  • Added stable chart IDs and parent/source references.
  • Made chart restore fault-tolerant so one bad chart does not abort the entire chat.
  • Prevented stale asynchronous chart results from landing in a different chat.
  • Included chart structured data in search and chart-generation context.
  • Added chart-focused regression coverage and updated search-highlight expectations.

Root cause

Chart data rules were duplicated between the agent, scene item, renderer, and persistence layers. Async insertion relied on the current node as a fallback, and charts were represented as loosely attached content without stable graph lifecycle metadata.

Validation

  • python -m pytest -q
  • Result: 408 passed, 1 existing asyncio deprecation warning
  • Focused chart/scene tests also pass.

@dovvnloading dovvnloading merged commit cf2cc6a into main Jul 15, 2026
6 checks passed
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.

1 participant