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

Log an error instead of crashing when loading state from a bad CC2531 #120

Merged
merged 1 commit into from
Dec 29, 2021

Conversation

puddly
Copy link
Collaborator

@puddly puddly commented Dec 24, 2021

Some users have been using CC2531 adapters that were flashed with Z-Stack 3 without being erased. Their TCLK NVRAM entry is technically too big but Z-Stack seems to still run. The ADDRMGR table, however, is too small. I'm not sure exactly how Z-Stack deals with that situation but it's out of scope for zigpy-znp to automatically do a complete network backup, an NVRAM erase, and a network restore to fix this problem. Instead, an error will be logged on startup.

home-assistant/core#61921

Some users have been using CC2531 adapters that were flashed with
Z-Stack 3 *without being erased*.  Their TCLK NVRAM entry is too big but
Z-Stack seems to still run.
@puddly puddly force-pushed the bugfix/backup-inconsistent-cc2531 branch from fdfaec9 to a1436bf Compare December 24, 2021 04:59
@codecov-commenter
Copy link

codecov-commenter commented Dec 24, 2021

Codecov Report

Merging #120 (a1436bf) into dev (03ee732) will decrease coverage by 0.02%.
The diff coverage is 91.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##              dev     #120      +/-   ##
==========================================
- Coverage   98.73%   98.71%   -0.03%     
==========================================
  Files          44       44              
  Lines        3876     3880       +4     
==========================================
+ Hits         3827     3830       +3     
- Misses         49       50       +1     
Impacted Files Coverage Δ
zigpy_znp/api.py 97.82% <90.00%> (-0.23%) ⬇️
zigpy_znp/tools/network_backup.py 97.91% <100.00%> (-0.05%) ⬇️
zigpy_znp/znp/security.py 95.18% <100.00%> (-0.08%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 03ee732...a1436bf. Read the comment docs.

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.

2 participants