-
-
Notifications
You must be signed in to change notification settings - Fork 656
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds missing CameraWidget registration for SCREEN_ON #4648
base: master
Are you sure you want to change the base?
Adds missing CameraWidget registration for SCREEN_ON #4648
Conversation
So just out of curiosity how do you expect this to work? The reason I ask is because entities in the if the entity is going to get more updates with this change we need to mention it in the docs but also have you done mobile data consideration here? Other entities dont really send that much data but a camera updating every time the screen turns on can be a hundred updates in a single day as opposed to the current default of 24 updates in a day. For example I had 77 screen on events yesterday that can lead to a lot of data usage unexpectedly |
That's a good point, but probably the responsibility of fetching the data should not be a SCREEN_ON intent, this should be used to trigger the necessary logic to do that, the point is that camera widget stays like this. I think docs can be updated that should not be a problem. To fetch data every 24 hours we could use camerawidgetnotworkingonscreenon.mp4
|
I agree but fixing that is not in scope of this proposed change, my comment was merely about the current architecture and how things work today.
i personally have not experienced that, in what cases do you see this happen? are there any errors in the logs when it happens. My camera widgets always show an image when I look at them and update appropriately when I tap on them. I can't quite tell what is going on in the video, if the image is not updating that suggests another issue as the image updates in the production app everytime I click on it. If the image is not updating the logs may help us determine whats wrong. I still dont see how the screen on intent will correct this.
Why change it when the current behavior works fine with the current refresh interval: https://github.com/home-assistant/android/blob/master/app/src/main/res/xml/camera_widget_info.xml#L11 I think it may be more helpful to understand the issue you are seeing so we can determine proper course of action. If the image s not updating when you tap on it the logs should show what happened there. |
Yes that's correct, maybe we could use part of the widget refactor to do that but on a separate PR?
I have seen this issue few times on my device, I can't really think of the scenario that made this happened, so I gave up using the camera widget. I'll try to find a way to reproduce and fetch the logs somehow.
I don't think changing the behavour is the solution, is ok as it is, but just to make sure to not fall in that edge case |
yea lets see what the actual issue is there as I am not seeing issues with this widget but that doesn't mean theres something that needs to be fixed somewhere! |
I have to look more in detail to this tomorrow hopefully |
|
Summary
Missing CameraWidget registration on SCREEN_ON, this will avoid the camera to refresh and sometimes will end up not loading the picture
Screenshots
Link to pull request in Documentation repository
Documentation: home-assistant/companion.home-assistant#
Any other notes
Split from #4640