slashback100 / presence_simulation

Home Assistant Presence Simulation
672 stars 26 forks source link

Detected integration that accesses the database without the database executor #53

Closed lostcontrol closed 2 years ago

lostcontrol commented 2 years ago

As seen in the logs with the latest 2022.4.0 HA version:

2022-04-07 14:19:33 WARNING (MainThread) [homeassistant.helpers.frame] Detected integration that accesses the database without the database executor; Use homeassistant.components.recorder.get_instance(hass).async_add_executor_job() for faster database operations. Please report issue to the custom component author for presence_simulation using this method at custom_components/presence_simulation/init.py, line 362: if result.count() > 0 and result[0][0] == "on":

faduchesne commented 2 years ago

same problem.

kwithus commented 2 years ago

Still that issue, any update in pipeline?

slashback100 commented 2 years ago

Correct me if I'm wrong but it is not a real issue yet, right?

kwithus commented 2 years ago

well, would prefer to get it corrected before the integration stops working because of this. i believe there is a reason when HA sends a warning

slashback100 commented 2 years ago

Yes, it's just that I have hard time making the requested adaptation 🤣

kwithus commented 2 years ago

That’s ok, as long as I know that you are planning to do and will do before it becomes critical, that’s fine with me. I am not a ‚code-person‘, musta ‚copy-paster‘, so I am glad for everyone providing content