Skip to content

Fix bhyve service calls on valve entities#391

Merged
sebr merged 2 commits intomainfrom
action-fixes
Apr 17, 2026
Merged

Fix bhyve service calls on valve entities#391
sebr merged 2 commits intomainfrom
action-fixes

Conversation

@sebr
Copy link
Copy Markdown
Owner

@sebr sebr commented Apr 17, 2026

Summary

  • bhyve.enable_rain_delay, disable_rain_delay, set_manual_preset_runtime and start_program were broken after the switch→valve conversion — the services were registered but the corresponding methods never got ported onto BHyveZoneValve, and the handler only searched the valve domain for target entities.
  • Moves websocket payload construction for rain delay and manual preset runtime onto BHyveClient, gives BHyveZoneValve thin service wrappers that delegate to the client, and routes the service handler through both the valve and switch domains so start_program finds program switches.
  • BHyveRainDelaySwitch.async_turn_on/off now call the same client methods, removing the duplicated _set_rain_delay implementation.

sebr added 2 commits April 17, 2026 02:05
The switch→valve conversion registered services like enable_rain_delay,
disable_rain_delay, set_manual_preset_runtime and start_program in the
valve platform but never ported the corresponding methods onto
BHyveZoneValve, so calling them with a valve entity errored out with
"Service not implemented". The service handler also only looked up
entities in the valve domain, breaking start_program on program
switches.

- Move websocket payload construction for rain delay and manual preset
  runtime onto BHyveClient, where the wire protocol belongs.
- Give BHyveZoneValve thin service wrappers that delegate to the client.
- Route the valve service handler through both VALVE_DOMAIN and
  SWITCH_DOMAIN so program switches can handle start_program, and
  surface unsupported (entity, service) pairs instead of aborting the
  whole loop.
- Collapse BHyveRainDelaySwitch turn on/off onto the shared client
  methods.
- services.yaml: quote the update_program.frequency description so the
  unescaped colon after "known values" no longer breaks YAML parsing.
- __init__.py: add CONFIG_SCHEMA = cv.config_entry_only_config_schema so
  hassfest's CONFIG_SCHEMA check passes now that async_setup exists
  without an inline schema.
@sebr sebr merged commit 9607232 into main Apr 17, 2026
4 checks passed
@sebr sebr deleted the action-fixes branch April 17, 2026 02:09
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 this pull request may close these issues.

1 participant