quickwit-datasource icon indicating copy to clipboard operation
quickwit-datasource copied to clipboard

fix: Fix autocomplete for adhoc filters for grafana v11.x

Open UN0wen opened this issue 7 months ago • 1 comments

fixes #144

My first PR, not too familiar with grafana scenes so I'm not sure where else to test but I've checked adhoc filters autocomplete on Grafana v10.4 and 11.4 and they were working correctly, please let me know if there are more places I should test.

Changes

It seems like we were using one of the optional fields (value) on MetricFindValue to filter for field capabilities, but it seems like from v11.x (not sure which version exactly, I only checked v11.4 mentioned in the issue) Grafana is using the value field as the key for both the final query and the autocomplete for tags, which leads to:

  • autocomplete fails because we're getting terms for field "field" : "string"
  • final query having string: <value> which most of the time returns nothing

Fixed this by renaming the field used for field capabilities to type

UN0wen avatar Apr 08 '25 02:04 UN0wen

Thanks for this PR. We are a bit short on maintainers for this plugin lately, so I can't really guaranty when we'll be able to review and merge this. Sorry 😞

rdettai avatar Apr 08 '25 11:04 rdettai

Thanks @UN0wen for the report. I'm going to fix this, supporting Grafana 12 is the target.

fmassot avatar Jul 17 '25 20:07 fmassot