{"record":{"id":"531069107a2d5185","repo":"slint-ui/slint","slug":"demos-json-is-incomplete-these-boards-failed-to-build-failed","errorCode":null,"errorMessage":"demos.json is incomplete, these boards failed to build: ${failed}","messagePattern":"demos\\.json is incomplete, these boards failed to build: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"scripts/build-demo-images.py","lineNumber":410,"sourceCode":"    with_mcu, with_p4 = args.only != \"p4\", args.only != \"mcu\"\n    if args.only == \"p4\" and not shutil.which(\"idf.py\"):\n        sys.exit(\"aborting: --only p4 needs idf.py from a full ESP-IDF >= 6.0 env\")\n    check_tools(BOARDS if with_mcu else [])\n\n    shutil.rmtree(out, ignore_errors=True)\n    out.mkdir(parents=True)\n\n    records: list[dict] = []\n    failed: list[str] = []\n    for enabled, build in ((with_mcu, build_mcu), (with_p4, build_p4)):\n        if enabled:\n            built, errors = build(out)\n            records += built\n            failed += errors\n\n    emit_demos_json(out, base, records)\n    if failed:\n        warn(\n            f\"demos.json is incomplete, these boards failed to build: {', '.join(failed)}\"\n        )\n        return 1\n    log(f\"done, images + demos.json in {out}\")\n    return 0\n\n\nif __name__ == \"__main__\":\n    sys.exit(main())\n","sourceCodeStart":392,"sourceCodeEnd":420,"githubUrl":"https://github.com/slint-ui/slint/blob/bb937076de3f7919766c1f25e2e969367cf77e9a/scripts/build-demo-images.py#L392-L420","documentation":"main in scripts/build-demo-images.py aggregates failed board features across all build stages. After emitting demos.json, if any boards failed it warns 'demos.json is incomplete, these boards failed to build: <list>' and returns exit code 1. The file is still written with whatever succeeded, so consumers can see it is partial; the non-zero exit lets CI mark the run failed.","triggerScenarios":"One or more board builds failed earlier in the run (build_mcu or build_p4 recorded failures) — e.g. a cargo compile error for a board target or an idf.py failure — and the script reached the end of main with a non-empty failed list.","commonSituations":"CI runs where one embedded target fails while others pass, producing partial demos.json artifacts; local partial builds accepted knowingly; flaky flashing tool causing intermittent board failures.","solutions":["Scroll up for the per-board failure warnings (266/268 style) and fix each underlying build error, then re-run","Re-run only the failed boards (e.g. with --only) once fixed","In CI, treat the exit code 1 as failed and block publishing demos.json","If a board is permanently unsupported in your environment, remove/narrow it from the board list"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if failed:\n    raise SystemExit(f\"refusing to publish demos.json; failed boards: {failed}\")","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Fix all per-board failures before publishing demos.json artifacts","In CI, fail the job on exit code 1 and gate artifact upload on it","Re-run failed boards with --only after fixes rather than shipping partial output","Monitor for recurring board failures and keep the board list green"],"tags":["build","ci","aggregation","exit-code"],"backgroundTag":"build-artifacts-incomplete","analyzedSha":"bb937076de3f7919766c1f25e2e969367cf77e9a","analyzedAt":"2026-09-16T01:37:20.251Z","contentChangedAt":"2026-09-16T01:37:20.251Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}