grafana / iot-sitewise-datasource

IoT Sitewise
Apache License 2.0
19 stars 9 forks source link

Expand Time Range does not account for pagination #315

Open chejimmy opened 1 month ago

chejimmy commented 1 month ago

What happened:

When the request paginating, the last observation (last data point before the time range) is also returned. However, when time series panel renders, it creates an extra line across the panel.

Related code https://github.com/grafana/iot-sitewise-datasource/blob/main/pkg/server/last-observation.go#L54C27-L54C41

What you expected to happen:

No last observation added to paginating request.

How to reproduce it (as minimally and precisely as possible):

  1. add a query with Expand Time Range support
  2. add an asset + property
  3. enable Expand Time Range
  4. select time range greater than 6 hour or any other ways to make query to paginate
  5. notice there's a line across the very first data point and the start of the second page of the data

Screenshots

See comment https://github.com/grafana/iot-sitewise-datasource/issues/315#issuecomment-2148185610

Anything else we need to know?:

Environment:

chejimmy commented 1 month ago

https://github.com/grafana/iot-sitewise-datasource/assets/50635800/a9c5a076-cc6d-432e-b36e-fcec0a3d963c

idastambuk commented 1 month ago

Hi @chejimmy thanks for reporting this! I've managed to reproduce it and will add it to our pipeline