wifwucite / esphome-ble-controller

Bluetooth Low Energy (BLE) controller for ESPHome
MIT License
109 stars 21 forks source link

Allow exposing internal components #11

Closed ashald closed 2 years ago

ashald commented 2 years ago

I was trying to setup esphome-ble-controller and couldn't figure out why I only saw the maintenance service. Only after I checked logs, I realized that all the sensors I was exposing were marked as internal, and esphome-ble-controller was ignoring them. I think it's a common pattern to use internal [template] sensors to format data etc, so that they're available on ESP, but are not pushed to HomeAssistant.

It'd be convenient if there was a flag to tell esphome-ble-controller that I want my internal services exposed over BLE. Also, it'd be very helpful if log messages such as about internal components being ignored would show up in the default log from ESP (to the best of my understanding they're only shown now if higher verbosity is enabled).

Thanks!

wifwucite commented 2 years ago

Hi, Oh this is actually a bug. Any component you expose explicitly should be exposed no matter if it is marked internal or not. Sorry for the inconvenience I had a similar issue myself when trying to expose an internal component via mqtt. Took me hours to debug because the log was saying it would be there although it was not. Anyway this should be fixed now. :-)

ashald commented 2 years ago

Thanks a lot!