Show status in History

Start a timer from it’s more-info window, then press a corr button on the right part of the window to show a History for the timer - does it show the started timer?

Also, I already suggested to do the same with input boolean.

If manual changes of timer & boolean are reflected in History - then sort out why these entities are not changed by automation.

Hi all,
at 7 pm or (19:00) a time pattern started my circulation pump. Here the trace of the automation:


After some checks the pump starts running, the timer is triggered.

After ~ 5 minutes the temperature in the system is high enough, and so the state of my input_boolean is set to ‘off’. This results in a trigger which is queued up for the moment.

In the next lap, the timer is canceled and the pump is switched off.
Thats it, no more triggers in the queue.
This is exactly I want to do and I am pretty sure it works out.

And here you can see, that the temperatures physically raises, so this is the best proof I can think off, it works.
And you can see, no reaction in the histrory plot, for what reason ever.

With beest regards

Gerhard

Hi all,
ok, I should check the history of the helper itself:


The whole day status ‘off’.
Ok, and who is triggering my automation?, please check the above traces …

Very mystic.

With best regards

Gerhard

3rd time: switch on/off this input_boolean. And check what is on the History.

Hi all,
and here the timer:


And the histrory of that timer after some time passed by:

And than the timer elapsed:

The automation is triggered and set the input_boolean to ‘off’. As the input_boolean was already in ‘off’ state, there is no listener in the automation for a state ‘change’ from ‘off’ to ‘off’, so no more trigger queued and the automation finishing at that point.

Ok, sorry, I cant’t do anything else …

With best regards
Gerhard

BTW.
I proposed to manually start a timer - and see how it is reflected in History.
Funny thing that I see no changes of my timer in History))))):

  1. Open History with the timer in one tab.

  2. On another tab - open more-info for the timer - and start it.

  3. On the History tab I see changes:

  4. Refresh the page or reopen the History - it has no changes:

It may happen only for entities excluded from Recorder.
But there are no mentions in “recorder.yaml” (which has “exclude” rules) for the timer.
On another test HA setup - which has no “recorder.yaml” specified - the history of the timer is shown.

Maybe you already answered this, but I do not see any input_boolean.turn_on service calls in the automation, so I have no idea how it would ever be on.

My timer is always manually started and shows up in history immediately. I use an automation, input_boolean and a script to manually complete the timer.

I’d be happy to share the automation code if you think it would help.

alias: Pihole disable
description: ""
trigger:
  - platform: state
    entity_id:
      - input_boolean.pi_hole_timer
    to: "on"
condition: []
action:
  - service: timer.start
    data:
      duration: "{{ states('input_number.pi_hole_timer') | int*60 }}"
    target:
      entity_id: timer.pi_hole_timer
  - service: switch.turn_off
    data: {}
    target:
      entity_id:
        - switch.pi_hole
  - service: homeassistant.update_entity
    target:
      entity_id:
        - switch.pi_hole_group
        - switch.pi_hole
    data: {}
  - delay:
      hours: 0
      minutes: 0
      seconds: "{{ states('input_number.pi_hole_timer') | int*60}}"
      milliseconds: 0
  - service: switch.turn_on
    data: {}
    target:
      entity_id: switch.pi_hole
  - service: input_boolean.turn_off
    data: {}
    target:
      entity_id: input_boolean.pi_hole_timer
  - service: homeassistant.update_entity
    target:
      entity_id:
        - switch.pi_hole_group
        - switch.pi_hole
    data: {}
mode: single

My timer history stay even after a refresh. Odd

Tested on another fresh empty setup (same 2024.2.5) with SAME recorder.yaml.
Timer changes are persistently shown in History even after F5.
Odd )))

Hmm, just created an “input_select” helper - and it is not saved in History. great.

Deleted all timers - then created new (with same names) timers.
These timers do have a History. Weird.
And after a couple of “timer start” - again no History.

1 Like

Hi petro,
the auotomation is triggered by an input_boolean (trigger 1) and this input_boolean is set/reset by a custom.button_card button, or a time pattern.
As you can see, it works fine.

Hi all the rest,
ok, seems there is some strange behaviour, ok, no problem, hope somebody with the right knowledge will find the time to fix it once a day.

With best reegards

Gerhard

PS: Today the calender sets my ‘holiday’ input_boolean to ‘on’, because I am in a rehabilitation facility trying to get my right leg ok again, and this was reflected in the history and also stops the activation of the circulation pump. ==> works fine. ==> my first real wold automation is ok.
Thanks all for helping.

Gerhard

Honestly we want to help! Maybe eliminate the custom button card step. I’ve seen delays with that mod.

Make it simple then extravagant, that’s my motto when problem solving.

Ok.
I am a newbee to HA, so what other control should I use instead?

With best regards

Gerhard

My setup uses a custom button, but the custom Button controls didn’t work for me either. I ended up creating a script with the finished the timer command.

My input boolean and the actual timer would get out of sequence and it would stop controlling the switch. The timer:cancel command was useless for me, but timer:finished worked well for my setup.

Hi LiQuid_cOOled,
I tested two things now.

First I add a switch card and linked it to my input_boolean which represents the state of the circulation system and which starts/stops the automation by triggers.
First trace: pump relay, second trace timer, third trace input_boolean ‘state’ and forth trace input_boolean ‘Holiday’.
I have to switch the holiday-mode off, than I started the circulation with this new switch. After some seconds I stopped it and I switched holiday on again (as a marker).
No changes in history.
Now I deleted the custom.button card, and do the same test, with the same result.

Some more tests, hope this test is the basic test, no easier/simpler test possible.
Create a helper of type timer called ‘test-timer’
Restart HA.
Click the test-timer in the list of ‘helpers’


… and click start.

Timer is counting down, as expected. Wait until thee timer expires.
Click the history button …

… sorry, but there is a bug.
Fresh timer, not linked to any other device/helper/entity and started from its own configuration UI, checked with its onw configuration UI …

With best regards

Gerhard

There may be, this is the second time I’ve heard someone having an issue with history, however the issue is not in history. If you look at the states table, there won’t be a state change. Something is blocking state changes from making it into the history table. It’s worth an issue as you’re not the first to mention this. A guy a few days ago was having the same issue with 2 input booleans.

Please mark it as a history problem and provide your states table and automation. This will be a hard issue to track down.

1 Like

Hi petro,
ok, will provide this info later.
Please tell me (I am newbee) where to get the requested infos easily. Thanks a lot

With best reegards

Gerhard

Hi petro,
I found at deveelopment tools somthing, and here the state of the timer changes:

With best regards
Gerhard

Hi,
any news?

With beest regards

Gerhard