Skip to content

Conversation

@Snuffy2
Copy link
Contributor

@Snuffy2 Snuffy2 commented Nov 11, 2024

Breaking change

This is the barely minimum viable product for the first PR. The bulk of this PR is the refactor of the data model. Please do not merge this into main/master. Maybe into a beta branch for those who'd like to help or test?

Rebuild of keymaster to utilize internal functions

  • Coordinator redesigned to manage the status of all keymaster locks and the link to the physical locks
  • Expand the KeymasterLock class to hold all of the necessary lock properties
  • Standardize the code of entities using a KeymasterEntity base class
  • Entities now get their value/state from the Coordinator
    • Converted existing Sensor and Binary Sensors
    • Added Text entities replacing input_text helper entities
  • Create a device for each lock in keymaster with all of the keymaster entities for it
    • For child locks, set the via_device property to link the parent lock to the child lock

Current functionality in this PR

  • Use existing keymaster setup (not sure it works for new setups yet)
  • Check and show whether keymaster lock is connected to the physical lock
  • Show code slot Name and PINs
  • Update PINs and synchronize changes made in parent to child locks

To Do in future PRs

  • Move input_boolean helper entities to switch entities
  • Move input_number to number entities
  • Move input_datetime to date, datetime or time entities
  • Add boltchecked lock entity
  • Add auto-lock timer entity
  • Ensure new and change configurations work properly
  • Store coordinator data to disk and restore on HA restart
  • Figure out if there is anyway to migrate from the current version to this one or if it will require a remove/reinstall

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (which adds functionality)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 2 times, most recently from 414a628 to be1c816 Compare November 11, 2024 18:22
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 6 times, most recently from 946c571 to 7e9d95c Compare November 12, 2024 00:02
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 8 times, most recently from 49c4138 to 7729f59 Compare November 12, 2024 13:34
@firstof9 firstof9 added code-quality breaking-change Changes that will require user intervention enhancement New feature or request labels Nov 12, 2024
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch from 7729f59 to 112dd33 Compare November 12, 2024 13:57
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 2 times, most recently from a30e648 to a82f7bd Compare November 13, 2024 01:23
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch from 5b62e02 to ba84cdb Compare November 14, 2024 04:45
Rename KeymasterLock entities from lock to kmlock
Rename KeymasterLock parent to parent_name
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch from ba84cdb to 83e4725 Compare November 14, 2024 04:49
@Snuffy2 Snuffy2 changed the title First step of moving to internal functions: Move input text to text First step of moving to internal functions: Minimum viable product Nov 14, 2024
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 4 times, most recently from 89f3388 to 4920fe0 Compare November 14, 2024 23:23
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 3 times, most recently from 092b8aa to 9e480a3 Compare November 15, 2024 03:13
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch from 9e480a3 to 0a6178f Compare November 15, 2024 03:17
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch 5 times, most recently from d9a24c1 to fcd62e2 Compare November 16, 2024 01:42
@Snuffy2 Snuffy2 force-pushed the Move-input_text-to-text branch from fcd62e2 to 06d24f0 Compare November 16, 2024 02:06
@Snuffy2 Snuffy2 marked this pull request as ready for review November 16, 2024 02:08
@firstof9 firstof9 changed the base branch from main to beta November 16, 2024 19:45
@firstof9 firstof9 changed the title First step of moving to internal functions: Minimum viable product refactor: First step of moving to internal functions: Minimum viable product Nov 19, 2024
@firstof9 firstof9 merged commit 2da4e1d into FutureTense:beta Nov 24, 2024
3 of 4 checks passed
@Snuffy2 Snuffy2 deleted the Move-input_text-to-text branch November 26, 2024 13:06
This was referenced Aug 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking-change Changes that will require user intervention code-quality enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants