Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

influxdb flux empty response causes error #320

Open
gabor opened this issue Jun 23, 2021 · 1 comment
Open

influxdb flux empty response causes error #320

gabor opened this issue Jun 23, 2021 · 1 comment

Comments

@gabor
Copy link

gabor commented Jun 23, 2021

when an influxdb flux query is used to feed data to the worldmap panel, it works fine (worldmap plugin uses the default configuration).

but, when i select a timerange where there is no data (so the flux query returns no data), the worldmap-plugin produces this error message:

Data error
TypeError: Cannot read property 'length' of undefined

the flux-data response contains one empty dataframe, and this seems to be the source of the problem.

to test this, just use a flux-query that returns no data, like:

from(bucket: "mybucket")
  |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
  |> filter(fn: (r) => r["_measurement"] == "cpu")
  |> filter(fn: (r) => r["_field"] == "usage_idle")
  |> filter(fn: (r) => false)
@gabor
Copy link
Author

gabor commented Jun 23, 2021

the issue originally reported in the grafana repo: grafana/grafana#30290

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

No branches or pull requests

1 participant