roleoroleo / yi-hack_ha_integration

Home Assistant custom integration for Yi cameras: yi-hack-MStar, yi-hack-Allwinner, yi-hack-Allwinner-v2, yi-hack-v5 and sonoff-hack
GNU General Public License v3.0
204 stars 32 forks source link

Media viewer in Home Assistant is broken due to Unknown Error #154

Open MiguelViana7 opened 2 weeks ago

MiguelViana7 commented 2 weeks ago

image

I've tried the steps in https://github.com/roleoroleo/yi-hack-Allwinner-v2/issues/380 to no avail, I've restarted both Home Assistant and the Camera, the motion events are viewable in the Yi-Hack web portal. Camera is running yi-hack-MStar

MiguelViana7 commented 2 weeks ago

Seems like I have this error in my logs

WARNING (MainThread) [homeassistant.helpers.frame] Detected that custom integration 'yi_hack' accesses hass.helpers.device_registry. This is deprecated and will stop working in Home Assistant 2024.11, it should be updated to import functions used from device_registry directly at custom_components/yi_hack/media_source.py, line 71: device_registry = self.hass.helpers.device_registry.async_get(self.hass), please create a bug report at https://github.com/roleoroleo/yi-hack_ha_integration/issues

I looked into it and this is the reference I found: https://developers.home-assistant.io/blog/2024/03/30/deprecate-hass-helpers/

adolfonovo commented 2 weeks ago

Same Here. I tried the suggested workaround without sucess

bedson87 commented 1 week ago

Same for me. HA 2024.6.3

adolfonovo commented 1 week ago

https://github.com/roleoroleo/yi-hack_ha_integration/pull/153/files

Making the changes suggested in that PR. the problems dissapears.

MiguelViana7 commented 1 week ago

Can confirm that making the changes in the PR fixed my issues as well, thank you for sharing!

roleoroleo commented 5 days ago

PR merged.