I have a prom query that returns my pvc usages if they are over a certain threshold in a Gauge chart.
Example:
((kubelet_volume_stats_used_bytes / kubelet_volume_stats_capacity_bytes) * 100) >= 30
This query returns:
{endpoint="https-metrics", instance="89.247.325.217:10250", job="kubelet", namespace="postgres", node="pool-1c5r15h-4pwmenbjse", persistentvolumeclaim="data-postgres-postgresql-0", service="kube-prometheus-kubelet"}
In my legend values field, I reference {{persistentvolumeclaim}}.
This works completely fine if the query returns multiple results. For example if I change the threshold of the query to >=30
(I overrode the display name for the pvc names, hence it shows "PVC: ...". The issue is also not related to the override, I tested it)
[Legend values displayed correctly]

Now if I change the threshold so that the query only returns one result, the label value is not displayed eventho it is being returned by the query. The label is showing when I choose the time series chart though. If I choose the Stat or Gauge chart the label is not displayed.
[Legend value not being displayed]

If I change the chart to the time series chart and remove the {{persistentvolumeclain}} reference from the legend, it clearly returns the result containing a persistentvolumeclaim field:
Does someone know if this is a grafana issue or might I have misconfigured something?
Tried explicitly overriding display name. Tried different chart types but it only works on the time series chart and state timeline chart.
