projects
/
openwrt
/
staging
/
xback.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8add3e1
)
build,json: fix generation with empty profiles
author
Paul Spooren
<
[email protected]
>
Mon, 21 Jun 2021 06:23:45 +0000
(20:23 -1000)
committer
Paul Spooren
<
[email protected]
>
Mon, 21 Jun 2021 19:43:21 +0000
(09:43 -1000)
If the image generation doesn't add any profiles to the output the
*profile merge* will fail. To avoid that set an empty profile as
fallback.
Signed-off-by: Paul Spooren <
[email protected]
>
(cherry picked from commit
fd0d9909bf50f114d5e7f7cedf53e542de878a2c
)
scripts/json_overview_image_info.py
patch
|
blob
|
history
diff --git
a/scripts/json_overview_image_info.py
b/scripts/json_overview_image_info.py
index 45c05012b1452acb13cc7cabbc7d517643848c44..db47fd9e426458c820bd878ca810d8ba2a87f672 100755
(executable)
--- a/
scripts/json_overview_image_info.py
+++ b/
scripts/json_overview_image_info.py
@@
-42,7
+42,7
@@
for json_file in work_dir.glob("*.json"):
output["profiles"][device_id]["images"].extend(profile["images"])
# make image lists unique by name, keep last/latest
-for device_id, profile in output
["profiles"]
.items():
+for device_id, profile in output
.get("profiles", {})
.items():
profile["images"] = list({e["name"]: e for e in profile["images"]}.values())