Skip to content
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

Multiple stations cannot be enabled/disabled with switch.turn_on or off #317

Open
cayossarian opened this issue Oct 12, 2024 · 1 comment · May be fixed by vinteo/py-opensprinkler#95
Open

Comments

@cayossarian
Copy link
Contributor

cayossarian commented Oct 12, 2024

Open Sprinkler Version 1.4.0
HA version core: 2024.10.2

In the Home Assistant developer tools pick any two open sprinkler stations as part of a switch.turn_on or turn_off action. Then trigger the action and what happens is the first station gets enabled then it gets disabled and the second station gets enabled.

When enabling or disabling multiple stations a log entry is shown that does not occur with a single station:

2024-10-11 20:04:32.295 INFO (MainThread) [backoff] Backing off _request_http(...) for 0.9s (pyopensprinkler.OpenSprinklerConnectionError: Cannot connect to controller)

I discovered this issue when adding labels for certain stations and attempting to enable/disable based on the label (a label can represent a collection of entities).

Performing a similar call on lights, for example, works reliably so the issue is not in HA.

@cayossarian cayossarian changed the title Multiple stations cannot be reliable enabled/disabled with switch.turn_on or off Multiple stations cannot be reliably enabled/disabled with switch.turn_on or off Oct 12, 2024
@cayossarian cayossarian changed the title Multiple stations cannot be reliably enabled/disabled with switch.turn_on or off Multiple stations cannot be enabled/disabled with switch.turn_on or off Oct 12, 2024
@EdLeckert
Copy link
Collaborator

Thanks for reporting this. I have submitted a proposed solution in the vinteo/py-opensprinkler project that corrects a timing issue.

While I was able to easily recreate this issue, I did not notice any OpenSprinklerConnectionError errors in the logs. That may have something to do with the speed of the host, controller, or network you're using. Or it could be unrelated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants