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

Schedule change after zone time adjustment #121

Open
gaborbozoky opened this issue Jun 15, 2023 · 7 comments
Open

Schedule change after zone time adjustment #121

gaborbozoky opened this issue Jun 15, 2023 · 7 comments

Comments

@gaborbozoky
Copy link

I have a 4 zones in sequence configuration which run every day at 3:00AM.

If I adjust more than 100% the zone's running time the schedule postpones the start time 2 days later.
If I adjust less than 100% the zone shedule missing from the card (and maybe from schedule too).

First time schedule:

image

The "rotor N zone"'s schedule is Sunday after time adjusted to 123%

image

And missing if I change it to 23%

image

My configuration:

=====================================================

irrigation_unlimited:
granularity: 1
refresh_interval: 5
history:
enabled: true
span: 7
refresh_interval: 120
controllers:
- name: "- garden controller"
enabled: true
preamble: "00:01"
postamble: "00:01"
all_zones_config:
show:
timeline: true
zones:
- name: "rotor N zone"
entity_id: "switch.irr_rotor_north_do"
allow_manual: true
show:
timeline: true
- name: "rotor S zone"
entity_id: "switch.irr_rotor_south_do"
allow_manual: true
show:
timeline: true
- name: "drop E zone"
entity_id: "switch.irr_drop_east_do"
allow_manual: true
show:
timeline: true
- name: "drop W zone"
entity_id: "switch.irr_drop_west_do"
allow_manual: true
show:
timeline: true
sequences:
- delay: "00:05"
name: "garden sequence"
schedules:
- name: "garden schedule"
enabled: true
anchor: start
time: "03:00"
month: [mar, apr, may, jun, jul, aug, sep, oct]
weekday: [mon, tue, wed, thu, fri, sat, sun]
zones:
- zone_id: 1
enabled: true
duration: "00:05:00"
repeat: 6
- zone_id: 2
enabled: true
duration: "00:02:30"
repeat: 6
- zone_id: 3
enabled: true
#duration: "00:04:20"
duration: "00:25:00"
repeat: 1
- zone_id: 4
enabled: true
#duration: "00:04:20"
duration: "00:25:00"
repeat: 1

-->

Version of the custom_component

V2023.6.1

Describe the bug

If I adjust more than 100% the zone's running time the schedule postpones the start time 2 days later.
If I adjust less than 100% the zone shedule missing from the card (and maybe from schedule too).

Debug log

2023-06-15 23:09:20.716 DEBUG (MainThread) [custom_components.irrigation_unlimited] LOAD
2023-06-15 23:09:20.719 DEBUG (MainThread) [custom_components.irrigation_unlimited] STOP
2023-06-15 23:09:20.719 DEBUG (MainThread) [custom_components.irrigation_unlimited] START
2023-06-15 23:09:28.586 INFO (MainThread) [custom_components.irrigation_unlimited] CALL [2023-06-15 23:09:28] service: adjust_time, controller: 1, zone: 1, data: {"percentage": 90.0, "entity_id": ["binary_sensor.irrigation_unlimited_c1_z1"]}
2023-06-15 23:12:58.212 DEBUG (MainThread) [custom_components.irrigation_unlimited] LOAD
2023-06-15 23:12:58.216 DEBUG (MainThread) [custom_components.irrigation_unlimited] STOP
2023-06-15 23:12:58.216 DEBUG (MainThread) [custom_components.irrigation_unlimited] START
2023-06-15 23:13:33.861 INFO (MainThread) [custom_components.irrigation_unlimited] CALL [2023-06-15 23:13:33] service: adjust_time, controller: 1, zone: 1, data: {"percentage": 123.0, "entity_id": ["binary_sensor.irrigation_unlimited_c1_z1"]}
2023-06-15 23:29:11.815 INFO (MainThread) [custom_components.irrigation_unlimited] CALL [2023-06-15 23:29:11] service: adjust_time, controller: 1, zone: 1, data: {"percentage": 123.0, "entity_id": ["binary_sensor.irrigation_unlimited_c1_z1"]}
2023-06-15 23:30:06.892 DEBUG (MainThread) [custom_components.irrigation_unlimited] LOAD
2023-06-15 23:30:06.896 DEBUG (MainThread) [custom_components.irrigation_unlimited] STOP
2023-06-15 23:30:06.898 DEBUG (MainThread) [custom_components.irrigation_unlimited] START
2023-06-15 23:30:17.652 INFO (MainThread) [custom_components.irrigation_unlimited] CALL [2023-06-15 23:30:17] service: adjust_time, controller: 1, zone: 1, data: {"percentage": 23.0, "entity_id": ["binary_sensor.irrigation_unlimited_c1_z1"]}

I'm not sure my config is okay but please help what's wrong?

Thanks,

Gabor

@gaborbozoky
Copy link
Author

After several try I found a workaround for this issue: after adjustment I must disable each zones then enable them. After this process the running times are seems okay. Live tests next days...

I can't decide is it a bug or behavior by design however I think the time adjustment should work without zone disable/enable.

Nevertheless, this integration is very useful and thanks for it!

@rgc99
Copy link
Owner

rgc99 commented Jun 16, 2023

Looks like you are reloading the config? Please be aware there are some fixes in the pipeline regarding the preservation of the enabled status and adjustments across a reload. An adjust_time service call should not require a reload. The reload is only required when changes have been made to the irrigation_unlimited: setup.

Please retest but do not use the reload. This will help to make sure it is not related to the other issue mentioned above.

@gaborbozoky
Copy link
Author

I used reload only to initialize the irrigation after the schedule corrupted to get back initial settings from YAML.

After I use adjust_time service call the scheduled time which showed by frontend card is corrupted. Then I disable the zone and enable again. After this disable/enable process the schedule is ok.

I do not know is it only a frontend card's problem or the schedule itself is corrupted too.

@rgc99
Copy link
Owner

rgc99 commented Jun 19, 2023

That's fine I understand. Please repeat the test but do not use reload as it currently has some known issues and may be creating a problem on another problem. These situations can be difficult to debug.

@ielbury
Copy link

ielbury commented Jul 2, 2023

This is a problem for me as well.

I am trying to figure out a suitable workaround ... missing watering cycles when it's REALLY hot is not good and the wife is ready to lobotomize me.

I am finding the only way to get things back on track is to reload.

@rgc99
Copy link
Owner

rgc99 commented Jul 3, 2023

Please update to version 2023.7.0

@mauritsivs
Copy link

Same here, after updating running times, the schedule gets messed up. Both visually in the card as well as actual working of the schedule. Missed some days of irrigation now when I was away... Disabling/enabling is current workaround for me now...

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

No branches or pull requests

4 participants