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

AuthorizationId doesn't change on rolling auth log #408

Closed
mutasim opened this issue Jun 20, 2024 · 3 comments · Fixed by #407
Closed

AuthorizationId doesn't change on rolling auth log #408

mutasim opened this issue Jun 20, 2024 · 3 comments · Fixed by #407
Labels
enhancement New feature or request
Milestone

Comments

@mutasim
Copy link

mutasim commented Jun 20, 2024

Version: 8.35

I've been experimenting with the Hass rolling_authorization_log sensor, the state + AuthorizationId attribute doesn't change for me when trying different codes/fingerprints.

The rest of the attributes do update correctly, but the state and AuthorizationId stay the same. Same with the AuthorizationId on lock/log on MQTT.

(Separately - I wonder if something like a timestamp would be a better state for the auth log sensor in Hass. I think this would make tracking events easier in the case where the same code/fingerprint is used again later that day for example. In the current implementation I can't see a clean/easy way to handle that scenario)

@propi62
Copy link

propi62 commented Jun 20, 2024

an easy way to trigger automations if code/fingerprint is entered.
also trigger automation whene last key entered is the same as before.
if homeassistant reboots the last key entered should not trigger the automation.

@iranl
Copy link
Collaborator

iranl commented Jun 21, 2024

State/AuthorizationId not changing with different codes/fingerprints is correct.
The keypad has one authorization (id) which is the same for all actions executed through the keypad, regardless of used code and method. Trigger and codeId are specific to certain codes and actions (e.g. fingerprint, arrow or code).

I do agree that it might not be the best value for the HA sensor.
I'll change it to index which will count up with every new log entry.

There are some more needed improvements on the rolling log as rebooting the ESP currently resets the rolling log and replays the max auth log count (default 5)

@iranl iranl added this to the 8.36 milestone Jun 21, 2024
@iranl iranl added the enhancement New feature or request label Jun 21, 2024
@propi62
Copy link

propi62 commented Jun 21, 2024

i am testing a workaround with any statechange of timeSecond as trigger.

trigger:
  - platform: numeric_state
    entity_id:
      - sensor.nuki_garage_rolling_authorization_log
    attribute: timeSecond
    above: -1
    below: 61

action:
  - conditions:
      - condition: state
        entity_id: sensor.nuki_garage_rolling_authorization_log
        attribute: authorizationName
        state: garagehaus (Keypad)
    sequence:
      - service: cover.toggle
        target:
          entity_id: cover.garagentor_haus
        data: {}
      - service: notify.mobile_app
        data:
          title: garagehaus (Keypad) triggered
          message: ""

@iranl iranl mentioned this issue Jun 22, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants