fix(board-db): sweep build.extra_flags across all enrichable boards (#298)#312
Conversation
…298) PR #299 unblocked FastLED CI for 3 priority nRF52840 boards by patching their JSONs manually. This is the follow-up broader sweep: re-runs enrich_boards (now with proper merge semantics) to restore build.extra_flags on every board family fbuild already shipped without the Arduino macros they need. Changes: * enrich_boards.rs: merge PIO-supplied build/upload fields into the existing fbuild JSON rather than wholesale replacing them. This preserves fbuild-only fields PIO no longer ships (e.g. legacy arduino.ldscript that PIO has moved into SCons builder scripts) while still picking up extra_flags, vid/pid, partitions, etc. * 601 board JSONs touched across 16 platforms: intel_mcs51 (264), atmelsam (81), libretiny (47), nordicnrf52 (45), microchippic32 (39), espressif32 (35), nordicnrf51 (14), timsp430 (13), freescalekinetis (12), maxim32 (9), infineonxmc (8), ststm8 (8), lgt8f (7), nxpimxrt (6), nxplpc (6), siliconlabsefm32 (5). Most gain a full extra_flags string with ARDUINO_<BOARD> / NRF52840_XXAA / etc. * tests: add test_nrf52840_sweep_arduino_macros covering the remaining Adafruit nRF52840 family (feather/clue/itsybitsy/metro/ledglasses/ circuitplay) and test_non_nrf52_sweep_arduino_macros covering SAMD (zero/mkrzero/adafruit_feather_m0), 8051 (AT89S51), and PIC32 (chipkit_uc32). Validation: * uv run python ci/validate_boards.py: 247 drift failures (down from 817 on main) -- remaining "extra in our asset" entries are intentional fbuild-only fields (e.g. build.arduino.ldscript). * soldr cargo check / clippy --workspace --all-targets -D warnings: pass * bash ./test (full workspace): 0 failures across all crates Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
Important Review skippedToo many files! This PR contains 300 files, which is 150 over the limit of 150. To get a review, narrow the scope: ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (300)
You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
enrich_boards.rsnow merges nestedbuild/uploadobjects instead of replacing them, so PIO-supplied values overlay onto fbuild-only fields likebuild.arduino.ldscriptrather than clobbering them.adafruit_feather_nrf52840,adafruit_clue_nrf52840,adafruit_itsybitsy_nrf52840,adafruit_metro_nrf52840,adafruit_ledglasses_nrf52840,adafruit_cplaynrf52840, etc.) now carries its Arduino-DARDUINO_<BOARD>/-DNRF52840_XXAAmacros.By platform: intel_mcs51 (264), atmelsam (81), libretiny (47), nordicnrf52 (45), microchippic32 (39), espressif32 (35), nordicnrf51 (14), timsp430 (13), freescalekinetis (12), maxim32 (9), infineonxmc (8), ststm8 (8), lgt8f (7), nxpimxrt/nxplpc (12), siliconlabsefm32 (5).
227 boards still lack upstream
extra_flags— libretiny (no Arduino macros upstream), Zephyr-only nRF boards, and platforms not available via stockpio platform install. Out of scope here; tracked as follow-up.Closes #298.
Test plan
test_nrf52840_sweep_arduino_macros,test_non_nrf52_sweep_arduino_macrosbash ./test(full workspace) — 0 failuressoldr cargo check/clippy --workspace --all-targets -- -D warnings— cleanuv run python ci/validate_boards.py— drift down from 817 → 247 (remaining are intentional fbuild-only fields)🤖 Generated with Claude Code