[OpenWrt-Devel] [PATCH] build: refactor JSON info files

Petr Štetiar ynezz at true.cz
Fri Feb 28 16:48:18 EST 2020


Paul Spooren <mail at aparcar.org> [2020-02-15 13:27:03]:

Hi,

> This PR refactors the JSON creation to store individual files in
> $(KDIR)/tmp and create an single overview file called `profiles.json` in
> the target dir.
> 
> As before, this creation is enabled by default only for the BUILDBOT.
> 
> To archive the previous behaviour the option JSON_INDIVIDUAL_JSON_INFO
> can be set.

Why do we need to preserve that previous behaviour?

FYI those individual files are broken[1] on some buildhosts (8C/16T, E5-2650) anyway:

 Traceback (most recent call last):
  File "/builds/ynezz/openwrt/scripts/json_add_image_info.py", line 49, in <module>
    device_info = json.load(json_file)
  File "/usr/lib/python3.5/json/__init__.py", line 268, in load
    parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
  File "/usr/lib/python3.5/json/__init__.py", line 319, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.5/json/decoder.py", line 342, in decode
    raise JSONDecodeError("Extra data", s, end)
 json.decoder.JSONDecodeError: Extra data: line 35 column 2 (char 823)

Would be nice to fix that and making this errors fatal so it's more visible and
can be fixed sooner then later.

> +jsonoverviewimageinfo: FORCE

nitpickbutyoucanusedashorundescoreifyouwantforsuchmultiwordtargetsormakethetargetnameshorter :)

1. https://ynezz.gitlab.io/-/openwrt/-/jobs/447337426/artifacts/logs/target/linux/install.txt

-- ynezz

_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list