M5 Stack Atom failed to update to latest firmware 2026.7.4

Initially the 2026.7.4 update failed to compile due to some breaking changes in my config,
‘WARNING Captive portal is enabled but no WiFi AP is configured. The captive portal will not be accessible. Add ‘ap:’ to your WiFi configuration to enable the captive portal.’
I added the ‘ap:’ to the yaml. I saved and validated the file, all ok, but the installation failed with the errors below:
FAILED: esp-idf/src/CMakeFiles/__idf_src.dir/main.cpp.obj
ccache /data/cache/idf/tools/xtensa-esp-elf/esp-14.2.0_20260121/xtensa-esp-elf/bin/xtensa-esp32-elf-g++ @esp-idf/src/CMakeFiles/_idf_src.dir/main.cpp.obj.rsp -MD -MT esp-idf/src/CMakeFiles/idf_src.dir/main.cpp.obj -MF esp-idf/src/CMakeFiles/idf_src.dir/main.cpp.obj.d -o esp-idf/src/CMakeFiles/idf_src.dir/main.cpp.obj -c /data/build/m5stack-atom-echo-3183e4/src/main.cpp
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:137:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
137 | then:
| ^
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:240:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
240 | - switch.is_on: use_listen_light
| ^~~~
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:253:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
253 | - switch.is_on: use_listen_light
| ^~~~~
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:272:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
272 | then:
| ^
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:281:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
281 | then:
| ^
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:289:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
289 | then:
| ^
/config/esphome/m5stack-atom-echo-3183e4.yaml: In lambda function:
/config/esphome/m5stack-atom-echo-3183e4.yaml:295:41: error: 'class esphome::template
::TemplateSelect<false, true, true, 1>’ has no member named ‘state’
295 | then:
| ^
ninja: build stopped: subcommand failed.
ninja failed with exit code 1, output of the command is in the /data/build/m5stack-atom-echo-3183e4/build/log/idf_py_stderr_output_28698 and /data/build/m5stack-atom-echo-3183e4/build/log/idf_py_stdout_output_28698

This has worked for a couple of years, why has it stopped?

https://esphome.io/changelog/2026.7.0/#native-toolchains-are-now-the-default-on-esp32-and-nrf52
This is from the changelog. Not sure if it helps.

please read this:

Your post is incredibly hard to read (the error messages) and you didn’t provide your configuration.

The errors you are seeing are caused by breaking changes in one or more of the releases since you last updated.

This is an example of one.
The old .state property for select entities was replaced by .current_option().

There might be additional things wrong.

I think you might have missed a deprecation

change .state to .current_option()