Matter Switch: Remove Energy Setters in added by hcarter-775 · Pull Request #2152 · SmartThingsCommunity/SmartThingsEdgeDrivers · GitHub
Skip to content

Matter Switch: Remove Energy Setters in added#2152

Merged
hcarter-775 merged 2 commits into
mainfrom
remove-energy-set
May 29, 2025
Merged

Matter Switch: Remove Energy Setters in added#2152
hcarter-775 merged 2 commits into
mainfrom
remove-energy-set

Conversation

@hcarter-775

Copy link
Copy Markdown
Contributor

Description of Change

Remove emit_event calls in added. In the case of powerMeter, this will be populated with a distinct value after subscribe occurs either in device_init or info_changed. It is the same in the case of energyMeter. In both cases, setting an initial value of 0 on added does not add any meaningful data to the capability handling, and so this is a wasted call.

Summary of Completed Tests

One test removed related to ensuring this was running.

@github-actions

github-actions Bot commented May 28, 2025

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

Test Results

   67 files    440 suites   0s ⏱️
2 250 tests 2 250 ✅ 0 💤 0 ❌
3 841 runs  3 841 ✅ 0 💤 0 ❌

Results for commit 17b2d60.

@github-actions

Copy link
Copy Markdown

File Coverage
All files 92%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/init.lua 93%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/embedded-cluster-utils.lua 38%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/third-reality-mk1/init.lua 95%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/eve-energy/init.lua 92%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/aqara-cube/init.lua 96%

Minimum allowed coverage is 90%

Generated by 🐒 cobertura-action against 17b2d60

Comment thread drivers/SmartThings/matter-switch/src/init.lua
@hcarter-775 hcarter-775 merged commit b583c61 into main May 29, 2025
11 checks passed
@hcarter-775 hcarter-775 deleted the remove-energy-set branch May 29, 2025 20:16
dljsjr pushed a commit that referenced this pull request Jun 9, 2025
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