Blueprints with Pyscript

Hey @swiftlyfalling. Thanks for his example. Very cool!

Been struggling with something similar and hoping maybe you have a pointer.
I’m looking to handle all my motion sensors logic in pyscript without a blueprint but having trouble figuring out the decorator to use that will fire for any “binary_sensor” event.

What I’m looking to do is shown here but using switches.

I can’t seem to figure out a generic catch-all for the motion sensors.
Any pointers? Thanks!