Skip to content

Bug: Data source names seem to be used as UID's in code if data source is set in a dashboard by a dashboard variable #187

@GrgDev

Description

@GrgDev

I tried using grafana-wtf recently with my instance of Grafana 11. However, I will get a giant list of warnings whenever I run any explore commands. They all mention basically the same thing, that a data source could not be found. (I had to replace the real names with placeholders here, but other than that, this is from an actual production instance.)

2025-03-28 15:48:16,170 [grafana_wtf.core                    ] WARNING : Data source 'datasource-1' not found
2025-03-28 15:48:16,170 [grafana_wtf.core                    ] WARNING : Data source 'datasource-2' not found
2025-03-28 15:48:16,170 [grafana_wtf.core                    ] WARNING : Data source 'datasource-3' not found

I went into the source code to see where this error is coming from and it seems to be coming from here.

log.warning(f"Data source '{ds_uid}' not found")

I see this line

log.warning(f"Data source '{ds_uid}' not found")

So it should be printing the UID, not the name, right? In my examples above, datasource-3 should have a UID of -iifrMA4k while datasource-2 should have a UID of YN2vilf7k. Yet that's not what is being printed. Is this a Grafana 11 specific issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions