fix: make the report directory before writing it

A platform with nothing left to correct writes no file, so its output
directory was never made: RetroPie's report then raised
FileNotFoundError into a fresh --output-dir and stopped --all.
This commit is contained in:
Abdessamad Derraz committed 2026-10-20 18:12:45 +02:00
1 parent d92291684c
commit 95476afb28
2 files changed
+11

No files matched your search

+3
View File
@@ -668,7 +668,10 @@ def write_report(path: Path, report: dict) -> None:
The run prints five examples per kind of change. The page lists them
all, so the maintainer reading it finds each line of the diff named.
A platform with nothing to write made no directory of its own: the
output directory itself may not exist yet.
"""
path.parent.mkdir(parents=True, exist_ok=True)
write_if_changed(str(path), json.dumps(report, indent=2) + "\n")