grafana / github-datasource

Grafana data source plugin using the Github API to retrieve and visualize Github data.
https://grafana.com/grafana/plugins/grafana-github-datasource/
Apache License 2.0
242 stars 53 forks source link

Templating: Fix error when response has data with empty array #317

Closed ivanahuckova closed 3 months ago

ivanahuckova commented 3 months ago

This PR addresses an issue where users encountered an error while creating template variables if the response contained an empty data array. The code has been updated to handle such cases.

Fixed (no error):

https://github.com/grafana/github-datasource/assets/30407135/af16218f-185f-429c-92b0-87bb582c094a

Broken (with error in the UI):

https://github.com/grafana/github-datasource/assets/30407135/f80de723-8654-475f-8337-7c566998012d