SmartThingsEdgeDrivers icon indicating copy to clipboard operation
SmartThingsEdgeDrivers copied to clipboard

fix an issue of device card color changed after Matter light power off and on

Open pInksenberg opened this issue 9 months ago • 2 comments

fix an issue of device card color changed after Matter light power off and on

Check all that apply

Type of Change

  • [ ] WWST Certification Request
    • If this is your first time contributing code:
      • [ ] I have reviewed the README.md file
      • [ ] I have reviewed the CODE_OF_CONDUCT.md file
      • [ ] I have signed the CLA
    • [ ] I plan on entering a WWST Certification Request or have entered a request through the WWST Certification console at developer.smartthings.com
  • [x] Bug fix
  • [ ] New feature
  • [ ] Refactor

Checklist

  • [ ] I have performed a self-review of my code
  • [ ] I have commented my code in hard-to-understand areas
  • [ ] I have verified my changes by testing with a device or have communicated a plan for testing
  • [ ] I am adding new behavior, such as adding a sub-driver, and have added and run new unit tests to cover the new behavior

Description of Change

When plug off the Matter light and then on, the color of the device card changed, This issue may be caused by the current code only process the report attribute while device onboarding, not handling the attribute report after the device goes offline and then back online, leading to an overwrite of the color mode.

Summary of Completed Tests

pInksenberg avatar Mar 26 '25 10:03 pInksenberg

Test Results

   65 files    419 suites   0s ⏱️ 2 141 tests 2 114 ✅ 0 💤 27 ❌ 3 660 runs  3 618 ✅ 0 💤 42 ❌

For more details on these failures, see this check.

Results for commit efd5459a.

github-actions[bot] avatar Mar 26 '25 10:03 github-actions[bot]

File Coverage
All files 86% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/color_utils.lua 9% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/init.lua 88% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/eve-energy/init.lua 91% :white_check_mark:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/aqara-cube/init.lua 96% :white_check_mark:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/embedded-cluster-utils.lua 38% :x:

Minimum allowed coverage is 90%

Generated by :monkey: cobertura-action against efd5459a3a6b7a1ae6fb44af8d5f015c6e737e15

github-actions[bot] avatar Mar 26 '25 10:03 github-actions[bot]