hassio-addons / addon-grafana

Grafana - Home Assistant Community Add-ons
https://addons.community
MIT License
221 stars 61 forks source link

error in grafana when using flux #222

Closed eddysteurs closed 2 years ago

eddysteurs commented 2 years ago

I use both Grafana and influxdb HA addons (both latest production releases)

when i use write a flux query on influxdb directly I get my data if I do this from within grafana I get the following error t=2021-11-03T08:12:11+0100 lvl=warn msg="Flux query failed" logger=tsdb.influx_flux err="Unexpected status code 401" query="from(bucket: \"home_assistant/autogen\")\r\n |> range(start: 2021-08-01T00:00:00Z, stop: 2021-11-02T00:00:00Z)\r\n |> filter(fn: (r) => r._measurement == \"kWh\" and (r._field == \"value\"))\r\n |> filter(fn: (r) => r.entity_id == \"monthly_energy_peak\")\r\n |> window(every: 1m0s)\r\n |> aggregateWindow(every: 1mo, fn: max)\r\n |> yield()" t=2021-11-03T08:12:11+0100 lvl=info msg="Request Completed" logger=context userId=1 orgId=1 uname=admin method=POST path=/api/ds/query status=400 remote_addr="192.168.0.11, 172.30.32.1" time_ms=7 size=342 referer="http://192.168.0.90:8123/api/hassio_ingress/8uQlQikXpWaBiH9Qi5HNB8tM6RgkpyHDxB9nMeoTiE0/d/M8LDsAFnz/test3?orgId=1"

what am I doing wrong?

github-actions[bot] commented 2 years ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!