blackcowmoo / grafana-google-analytics-datasource

Grafana Google Analytics datasource
https://grafana.com/grafana/plugins/blackcowmoo-googleanalytics-datasource/
Apache License 2.0
38 stars 17 forks source link

Issues when selecting Date + Hour in Time Dimension #121

Open aa-matthias opened 2 months ago

aa-matthias commented 2 months ago

Describe the bug When selecting Date + Hour in Time Dimension queries stop showing. The error i get via Grafana Log is:

logger=plugin.blackcowmoo-googleanalytics-datasource t=2024-09-12T16:31:29.306872536+02:00 level=error msg=timeConverter error="parsing time \"(other)00000\" as \"200601021504\": cannot parse \"(other)00000\" as \"2006\"" logger=plugin.blackcowmoo-googleanalytics-datasource t=2024-09-12T16:31:29.306909005+02:00 level=error msg="parseRow: Failed to parse time dimension" error="parsing time \"(other)00000\" as \"200601021504\": cannot parse \"(other)00000\" as \"2006\""

Grafana Version & Plugin Version 11.2.0 with 0.3.0

To Reproduce Steps to reproduce the behavior: Query as shown in the Screenshot below - Data stops loading (changing Time Dimension to something else works)

Expected behavior Graph should be shown as usual.

Screenshots image

Additional context Add any other context about the problem here.

lcc3108 commented 2 months ago

image

When I tested it, it was operating normally.

Can you give me more detailed information for reproduction?

aa-matthias commented 2 months ago

I actually cannot provide that much - worked on friday, broken today again... is there a way to fetch the raw result returned by the google api to diagnose that?

lcc3108 commented 2 months ago

change log.level=debug grafana.ini file

https://github.com/grafana/grafana/blob/main/conf/defaults.ini#L1055

https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/#log

lcc3108 commented 1 month ago

@aa-matthias As a result of analyzing the data, I think there was a change in the ga api. <-- Maybe

When the amount of data increases, the rest of the values are added to the field (other).

This operates independently of the maximum row number of api requests.

Let me look more closely at the ga api policy.

In the above case, the field of the date hour must be parsed by time, but it occurs because the other cannot be time parsed due to other changes.

lcc3108 commented 1 month ago

https://support.google.com/analytics/answer/13331684?hl=en

aa-matthias commented 1 month ago

thanks - sorry, i kept having this topic in my backlog but missed to reply so far.