Supposed to fix #4069, by changing the default value to 0s (timeunit instead of int) to pass validation (#4806)

Co-authored-by: Alex1602 <alex1602@gmail.com>
This commit is contained in:
Alex Dekker 2023-05-11 23:25:34 +02:00 committed by GitHub
parent cd7e8e4bdd
commit 9cbf437509
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -275,7 +275,7 @@ SPRINKLER_ACTION_SET_RUN_DURATION_SCHEMA = cv.Schema(
SPRINKLER_ACTION_QUEUE_VALVE_SCHEMA = cv.Schema( SPRINKLER_ACTION_QUEUE_VALVE_SCHEMA = cv.Schema(
{ {
cv.Required(CONF_ID): cv.use_id(Sprinkler), cv.Required(CONF_ID): cv.use_id(Sprinkler),
cv.Optional(CONF_RUN_DURATION, default=0): cv.templatable( cv.Optional(CONF_RUN_DURATION, default="0s"): cv.templatable(
cv.positive_time_period_seconds cv.positive_time_period_seconds
), ),
cv.Required(CONF_VALVE_NUMBER): cv.templatable(cv.positive_int), cv.Required(CONF_VALVE_NUMBER): cv.templatable(cv.positive_int),