sh00t2kill / linktap_local_http_component

A Custom Component that uses the linktap local HTTP API
25 stars 3 forks source link

Default Time and Manual watering #50

Open derhally opened 1 week ago

derhally commented 1 week ago

I just configured the LinkTap integration and everything is working except I can't seem to figure out how to switch the "Default Time" to false and have it honor my water duration setting.

image

I thought it was false before, but when I reloaded the integration it was back to true.

sh00t2kill commented 1 week ago

Does the duration entity listed as an attribute match the entity created by the integration?

I've only seen this happen when there's an issue with the name matching

derhally commented 1 week ago

I don't know what caused it, but the names were not matching. Not sure if the issue was that I imported the linktapper then renamed it in home assistant and then I went back to the LinkTap app and renamed it there to match the name in Home Assistant and there was some delay in everything being in sync.

I saw these in the debug logs

2024-07-05 22:02:15.503 DEBUG (MainThread) [custom_components.linktap.switch] Entity number.linktap_taplinker_watering_duration not found -- setting default
2024-07-05 22:02:15.503 DEBUG (MainThread) [custom_components.linktap.switch] Set duration:15

I unloaded the integration got everything named on the TapLink side, then added the integration back and everything seems to be working as expected.

sh00t2kill commented 1 week ago

That's a good point; renaming the entity_id for the number will break the integration.

I'll look at improving how that works in the future.

argoon38 commented 1 day ago

Hi, I've got the same issue. Actually, I've got 3 Lintap and all have the same attribute duration_entity: number.linktap_taplinker_watering_duration

@derhally, what do you mean by 'I unloaded the integration'? Do you mean Reload action?

sh00t2kill commented 1 day ago

Hi, I've got the same issue. Actually, I've got 3 Lintap and all have the same attribute duration_entity: number.linktap_taplinker_watering_duration

@derhally, what do you mean by 'I unloaded the integration'? Do you mean Reload action?

In a nutshell, renaming things breaks the integration horribly. Don't do it.

Make sure your taps are named in linktap as you want them. Delete the integration and re-add it.