Share one unsupported-toolchain check across platforms

This commit is contained in:
J. Nick Koston
2026-08-20 13:58:46 -05:00
parent c7e1d044a3
commit bbf2788684
6 changed files with 24 additions and 22 deletions
+3 -3
View File
@@ -557,9 +557,9 @@ def _add_library_str(lib: str) -> None:
@coroutine_with_priority(CoroPriority.FINAL)
async def _add_platformio_options(pio_options: dict[str, str | list[str]]) -> None:
if CORE.using_toolchain_esp_idf or (
CORE.using_toolchain_arduino and CORE.is_esp8266
):
# Every platform's toolchain validation rejects values it cannot serve,
# so using_toolchain_arduino by itself implies the native ESP8266 build.
if CORE.using_toolchain_esp_idf or CORE.using_toolchain_arduino:
# The native builds don't read platformio.ini; honor the options
# with a native equivalent and warn about the rest, which would
# otherwise be silently ignored.