Group.all_lights is gone, how to query for all entity ids of lights that match a lambda?

In regards to this issue, how do you query all entity_id of all lights that match a particular state? (Like being on?)

This has been useful to me…so here you go!

Got it, thanks