finos / perspective

A data visualization and analytics component, especially well-suited for large and/or streaming datasets.
https://perspective.finos.org/
Apache License 2.0
7.73k stars 1.05k forks source link

When rendering of split headers when using a data in the Split By field, the re-rendering on table.update adds rows #2517

Closed ramirezg-web closed 5 months ago

ramirezg-web commented 5 months ago

Bug Report

When rendering of split headers when using a data in the Split By field, Perspective table.update() adds rows instead of re-rendering table with updated values

Steps to Reproduce:

  1. Find replication of issue here: Reproduction:https://codesandbox.io/p/sandbox/serene-albattani-h96wxj Use Perspective Viewer to render the table
  2. await 3 seconds per the setTimeout function
  3. the table adds rows

Expected Result:

Expected to see table render with updated values

Actual Result:

Expected to see updated values, but new rows were added. Reproduction:https://codesandbox.io/p/sandbox/serene-albattani-h96wxj

Environment:

Perspective 2.7.1 MacOS Ventura 13.6.1 Chrome Browser 120.0.6099.234 (Official Build) (x86_64)

timkpaine commented 5 months ago

Your initial data is created on the 22nd

        const table = await worker.table(createData(22), {

But you update with data from the 26

          const newData = createData(26);

So I think the behavior is correct? Please let me know if I'm reading this wrong