Skip to content

zigbee-lock: support programmingUser typed entries - #3332

Merged
hcarter-775 merged 9 commits into
mainfrom
feat/zigbee-lock-master-code-distinct
Nov 13, 2026
Merged

hcarter-775 merged 9 commits into
mainfrom
feat/zigbee-lock-master-code-distinct

Conversation

@hcarter-775

@hcarter-775 hcarter-775 commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

Description of Change

Represent the Zigbee master code pins as a programmingUser, keep it across delete-all, refuse to delete these kinds of codes, refuse to create these kinds of codes, and promote reported codes to master when the lock says so. A user cannot be changed to or from the programmingUser type via updateUser, and auto-assigned credentials start at index 1 so they never claim the master slot.

Move Yale-specific handling into its own sub-driver, which normalizes Yale's misreported user ids.

Extend the lockCodes migration to take the known master code slot (0 for Yale) and always migrate it as a programming user.

Summary of Completed Tests

Tested on-device. Unit tests updated.

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Channel deleted.

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

zigbee-lock_coverage.xml

File Coverage
All files 94% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/legacy-handlers/migrate.lua 98% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/legacy-handlers/init.lua 95% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/configurations.lua 95% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/init.lua 99% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/lazy_load_subdriver.lua 57% ❌
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/lock_utils/utils.lua 97% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/lock_utils/tables.lua 98% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/samsungsds/init.lua 89% ❌
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/legacy-handlers/yale/init.lua 92% ✅
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/lock_handlers/zigbee_responses.lua 86% ❌
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/zigbee-lock/src/lock_handlers/capabilities.lua 89% ❌

Minimum allowed coverage is 90%

Generated by 🐒 cobertura-action against 6b63c58

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Test Results

   73 files    571 suites   0s ⏱️
3 390 tests 3 390 ✅ 0 💤 0 ❌
5 431 runs  5 431 ✅ 0 💤 0 ❌

Results for commit 6b63c58.

♻️ This comment has been updated with latest results.

@hcarter-775
hcarter-775 force-pushed the feat/zigbee-lock-master-code-distinct branch from bb08c2c to b71ef21 Compare November 6, 2026 18:15
@hcarter-775
hcarter-775 force-pushed the simplify-reported-cred-management branch from 1eab2cd to 528c7fb Compare November 6, 2026 19:59
@hcarter-775
hcarter-775 force-pushed the feat/zigbee-lock-master-code-distinct branch from b71ef21 to 8e976ad Compare November 6, 2026 20:00
@hcarter-775
hcarter-775 force-pushed the simplify-reported-cred-management branch from 528c7fb to 4192673 Compare November 9, 2026 21:34
@hcarter-775
hcarter-775 force-pushed the feat/zigbee-lock-master-code-distinct branch from 8e976ad to d96af15 Compare November 11, 2026 17:48
Base automatically changed from simplify-reported-cred-management to main November 11, 2026 19:47
hcarter-775 and others added 5 commits November 12, 2026 10:41
Represent the Zigbee master code (credential index 0) as a master
user, keep it across delete-all, and promote reported codes to master
when the lock says so. A user cannot be changed to or from the master
type via updateUser, and auto-assigned credentials start at index 1 so
they never claim the master slot.

Move Yale-specific handling into its own sub-driver, which normalizes
Yale's misreported user ids and refuses to delete the master code.

Extend the lockCodes migration to take the known master code slot (0 for
Yale) and always migrate it as a master user.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@hcarter-775
hcarter-775 force-pushed the feat/zigbee-lock-master-code-distinct branch from 2f1c3fd to 7e9a2d7 Compare November 12, 2026 17:29
@hcarter-775 hcarter-775 changed the title zigbee-lock: support master codes zigbee-lock: support programmingUser typed entries Nov 12, 2026

@tpmanley tpmanley left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like you handled all the stuff we discussed offline so I think this look good to go

@hcarter-775
hcarter-775 merged commit 9322d21 into main Nov 13, 2026
22 checks passed
@hcarter-775
hcarter-775 deleted the feat/zigbee-lock-master-code-distinct branch November 13, 2026 17:55
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

Successfully merging this pull request may close these issues.

3 participants