Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logs Samples: Panel wrongly visible when using datasource without Log-Sample support #65041

Closed
svennergr opened this issue Mar 20, 2023 · 0 comments · Fixed by #65357
Closed
Assignees
Labels
area/explore prio/high Must be staffed and worked on either currently, or very soon, ideally in time for the next release. type/bug

Comments

@svennergr
Copy link
Contributor

svennergr commented Mar 20, 2023

What happened:

We added the Logs sample feature a couple of weeks ago. That panel is used for datasources which can provide samples of logs when their data representation is not logs. With other words, this is mainly used for Loki's metric queries to see some samples of the underlying log data.
However with the change in #63036 the relevant logic to display or hide the container was changed.

Basically the container relies on this logic here:
https://github.com/grafana/grafana/blob/main/public/app/features/explore/Explore.tsx#L578

Mainly, when logsSample.dataProvider is undefined the panel will be hidden. However in #63036 there was a change of the default return value of such data providers: https://github.com/grafana/grafana/pull/63036/files#diff-dd4066243e4f35893e0fa409792e0901d44cebd250b8fc3784e1a1d0718b5782R129-R132

What you expected to happen:

Logs sample container for other datasources then Loki.

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

  1. Start Grafana
  2. Start a Tempo
  3. Go to Explore and make a query to Tempo
  4. Logs sample is visible below the trace result table

Environment:

  • Grafana version: main (9.5.0-53559pre)
@L-M-K-B L-M-K-B added the prio/high Must be staffed and worked on either currently, or very soon, ideally in time for the next release. label Mar 20, 2023
@L-M-K-B L-M-K-B self-assigned this Mar 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/explore prio/high Must be staffed and worked on either currently, or very soon, ideally in time for the next release. type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants