I don’t get what this error is

It’s an esp32 and I copied the “sensor: “ with the bmp section from the esphome website, so the formatting should be correct. Does anyone have any idea what could cause the error in line 15?

Hover your mouse over the wavy red line. What does it say?

If its VSCode, then it may not be an error. I have had lots of times where VSCode craps itself on identifying errors

Welcome @arthurandreas.

Please take a moment to figure out how to post formatted code. It does really help us help you.

See here. It’s worth reading the whole thing.

Cheers.

Hey Mahko, I’m sorry, but pc had some problems and I wrote the YAML code in espHome in the Hass App on my phone, where I wasn’t able to copy the code.
But Guys I’m sorry, I found my mistake. I forgot to add the i2c component. Sorry, I forgot that it’s a new esp and not one of my old ones, which all have this component. But thanks a lot for the help!

1 Like