Billboard.js: Incompletes timeseries tooltip bug (wrong data displayed)

Created on 2 Jul 2019  路  5Comments  路  Source: naver/billboard.js

Description

I try to load 2 differents timeseries in the same chart but I encounter a bug with the data displayed in tooltip.

Steps to check or reproduce

See https://stackblitz.com/edit/uxszjg?file=index.ts

My first timeserie has 6 values, and I load a second timeserie with only 5 values (supposing that we don't have to data for this date) without unloading the first one. All linechart points are placed to their corresponding date but when hovering, lets say, the first data, the tooltip is displaying n+1 data for the second timeserie.

Thanks by advance for your help !

bug released

All 5 comments

Hi @eweap, do you have any issue load additional data like this way?

setTimeout(function() {
    chart.load({
        columns: [
                ["data2", null, 220, 150, 40, 250, 150]
        ]
    });
}, 1000);

@netil The problem is that the following outputs come from 2 distinct API calls:

[
    // 6 values
    ["x", "2013-01-01", "2013-01-02", "2013-01-03", "2013-01-04", "2013-01-05", "2013-01-06"],
    ["data1", 30, 200, 100, 400, 150, 250]
]

and

[
    // 5 values
    ["x", "2013-01-02", "2013-01-03", "2013-01-04", "2013-01-05", "2013-01-06"],
    ["data2", 220, 150, 40, 250, 150]
]

The API returns only the data it has (that's why there can be different dates between timeseries) and timeserie are loaded progressively (after each API call) in the chart with load.

Should I extract all previously loaded data from the chart to check every missing date and try to find the right index to fill with null ? Even if it is feasible it seems to me not the right way to go.

The library has all the data it needs to do this work itself no ? I think this should be done internally.

What are your toughts about it ?

Thanks.

@eweap, I misunderstood the issue.
It seems the tooltip isn't aligned correctly with the data loaded.

Thanks for the report!

:tada: This issue has been resolved in version 1.10.0-next.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket:

:tada: This issue has been resolved in version 1.10.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

drazik picture drazik  路  4Comments

programmiana picture programmiana  路  5Comments

creage picture creage  路  4Comments

davidhund picture davidhund  路  5Comments

AyshvaryaLaxmiK picture AyshvaryaLaxmiK  路  5Comments