Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ grafana-wtf changelog

in progress
===========
- Fixed 404 error on "dash-folder" type when enumerating dashboards.
Thanks, @oxy-star and @GarbageYard.

2025-03-18 0.23.0
=================
Expand Down
2 changes: 2 additions & 0 deletions grafana_wtf/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,8 @@ def fetch_dashboards(self):
log.info("Fetching dashboards one by one")
results = self.data.dashboard_list
for dashboard_info in results:
if dashboard_info.get("type") == "dash-folder":
continue
self.fetch_dashboard(dashboard_info)

def fetch_dashboards_parallel(self):
Expand Down
5 changes: 2 additions & 3 deletions tests/test_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ def test_log_all(ldi_resources, capsys, caplog):
# Verify output.
assert "Aggregating edit history for multiple Grafana dashboards" in caplog.text
history = json.loads(captured.out)
assert len(history) == 3
assert len(history) == 2


def test_log_json_success(ldi_resources, capsys, caplog):
Expand Down Expand Up @@ -400,7 +400,7 @@ def test_log_yaml_success(ldi_resources, capsys, caplog):

data = yaml.safe_load(captured.out)

assert len(data) == 3
assert len(data) == 2


def test_log_filter_sql(ldi_resources, capsys, caplog):
Expand Down Expand Up @@ -429,7 +429,6 @@ def test_log_filter_sql(ldi_resources, capsys, caplog):
assert set(captured.out.strip().split("\n")) == {
"- url: http://localhost:33333/d/ioUrPwQiz/luftdaten-info-generic-trend-v27",
"- url: http://localhost:33333/d/jpVsQxRja/luftdaten-info-generic-trend-v33",
"- url: http://localhost:33333/dashboards/f/testdrive/testdrive",
}


Expand Down