mago0211 / home-assistant-custom-component-velux2

GNU General Public License v3.0
0 stars 1 forks source link

Covers are not reporting closed state anymore #1

Open pergolafabio opened 2 years ago

pergolafabio commented 2 years ago

Hey @mago0211

i was running your custom for the limitation Now thats getting back sunny i opened the covers for a long while, they then offocurse report "open", but when i close them, seems they are stuck in "open" state, not reporting closed anymore...

do you see the same issue here?

when i restart HA again, its back OK,

seems after 2 min i think, i dont see any reporting anymore

image

pergolafabio commented 2 years ago

Now testing back the original component without limitation, and then it seems to be fine ... ass soon its closed, its instanntly reporting closed

any idea what could be wrong?

pergolafabio commented 2 years ago

Also see this in log, not sure if its related

2022-04-20 18:40:48 ERROR (MainThread) [custom_components.velux2.cover] Error fetch limitation data for cover velux_rechts

mago0211 commented 2 years ago

Hi,

Now testing back the original component without limitation, and then it seems to be fine ... ass soon its closed, its instanntly reporting closed

any idea what could be wrong?

you are going to the standard velux integration with pyvlx==0.2.19 or do you only remove the limitation feature and use pyvlx==0.2.20

It's looks like a little bit the same problem as in https://github.com/Julius2342/pyvlx/issues/153 described. Maybe the Gatway comes in trouble if to many thing in parallel where to do.

The limitation feature is only polling based this makes a high traffic in the Gateway. I think this must be handled by pyvlx library. Maybe I can investigate this.

pergolafabio commented 2 years ago

When i test your custom, i use indeed 0.2.20 , then i can reproduce the issue verry easy, as soon as i open/close the cover, the issue always occurs when i dont use your custom, and use the official integration, with 0.2.19 , then i dont have any issues at all

so is it related to 0.2.20 OR the limitation feature ....

pergolafabio commented 2 years ago

Hi, did you figured something out already?

mago0211 commented 2 years ago

Not really. The only thing I have seen so far is when I do many actions in parallel e.g. Open 5 Windows parallel then mostly 1 Report no position after moving,

Currently I don't know why. I have activate some logging in pyvlx and I see there comes no report from the Gateway. It looks like this is an Issue from the Gateway it self. The limitation is polling based. So if the Gateway has problem's with to many requests at the same time this could increase the problem.

pergolafabio commented 2 years ago

AHH, thats maybe why i see the issue now, since i'm using your custom before i use my own custom component, but using the new pyvlx BUT, i was only polling one velux , no both of them, i hardcoded it...

Is it maybe a workaround to make a variable , so we can turn on/off the polling ? So we just poll 1 velux instead of them all? we dont need rain sensors for all of them :-)

pergolafabio commented 2 years ago

hey @mago0211 , how can i change your custom component, so only 1 min_limitation value is retrieved on 1 velux? maybe thats the issue that its polling my 2 velux?

and also skip the limitation max, we dont need that anyway

or how can we proceed with this? :-)

pergolafabio commented 2 years ago

Just for info, I now have for severe weeks the interval on 5 min instead of 2, seems stable , no more lockup of gateway