-
Notifications
You must be signed in to change notification settings - Fork 7.7k
fix(zigbee): Replace assert with error log to solve immediate crash #11614
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
Conversation
👋 Hello P-R-O-C-H-Y, we appreciate your contribution to this project! 📘 Please review the project's Contributions Guide for key guidelines on code, documentation, testing, and more. 🖊️ Please also make sure you have read and signed the Contributor License Agreement for this project. Click to see more instructions ...
Review and merge process you can expect ...
|
Test Results 76 files 76 suites 13m 7s ⏱️ Results for commit c60654c. ♻️ This comment has been updated with latest results. |
Memory usage test (comparing PR against master branch)The table below shows the summary of memory usage change (decrease - increase) in bytes and percentage for each target.
Click to expand the detailed deltas report [usage change in BYTES]
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR replaces an assertion-based error check with graceful error handling in the Zigbee commissioning callback to prevent system crashes when commissioning is already in progress.
- Replaces
ESP_ERROR_CHECK
with conditional error logging to allow retry mechanisms to function - Prevents immediate crashes when
esp_zb_bdb_start_top_level_commissioning()
returnsESP_FAIL
- Aligns implementation with current esp-zigbee-sdk examples
Description of Change
Replace
ESP_ERROR_CHECK
with proper error handling to prevent system crashes whenesp_zb_bdb_start_top_level_commissioning()
returnsESP_FAIL
due to invalid commissioning state (can be in progress). This allows the existing retry mechanism to continue working while providing better error logging instead of assertion failures.Same way its now done in esp-zigbee-sdk examples:
Tests scenarios
Tested using some Zigbee example with rebooting many times.
Related links
Closes #11554