Repository navigation
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #778 +/- ##
=======================================
Coverage 99.59% 99.59%
=======================================
Files 64 64
Lines 4417 4423 +6
=======================================
+ Hits 4399 4405 +6
Misses 18 18 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are identified for the source-route configuration and discovery changes.
No open issues 🎉
What changed in this PR
This PR addresses stale source routes by defaulting the NCP source-route table to zero when source routing is disabled, while preserving explicit table-size overrides.
Changes:
- Apply the adjusted table configuration during connection and reset.
- Schedule immediate source-route discovery when enabled and honor forced route discovery regardless of source-routing mode.
- Add configuration and packet-option tests, and update the discovery-mode assertion.
| File | Description |
|---|---|
tests/test_ezsp.py |
Expect RESCHEDULE when enabling source routing. |
tests/test_application.py |
Cover table-size defaults, explicit overrides, and forced discovery with source routing. |
bellows/zigbee/application.py |
Adjust table configuration and honor forced route discovery. |
bellows/ezsp/__init__.py |
Request immediate discovery with RESCHEDULE. |
Review effort: Balanced
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #772.
Source routing in EmberZNet is a little broken/odd and is kind of already half-enabled by default:
SOURCE_ROUTE_FAILUREproperly.The end result is as the above issue described, bad source routes are used and there's no way to evict them. The only way I can find to do so is to completely disable source routing if it is not enabled by setting the table size to 0 on startup.
zbee_nwk.src_route == Truein Wireshark finds no source routing packets sent at all.AODV route discovery seems to help in the case where a source route is unknown and the stack hasn't performed a MTORR to discover a source route to the destination. With our (now) short MTORR intervals this should be less of a problem but it should still help.
Since this is a bugfix PR for source routing, I've rolled in #716.
Should be released along with zigpy/zigpy#1982, as AODV-only routing is less performant 1.
Footnotes
I actually see less popcorning with source routing fully disabled than I did in the "hybrid" mode EmberZNet uses by default, for some reason! Routing in this mode feels more stable and stutters less, somehow. ↩