Skip to content

Remove Aqara Pet Feeder "legacy" quirks from ZHA - #883

Open
iamjoshk wants to merge 10 commits into
zigpy:devfrom
iamjoshk:iamjoshk-aqarapetfeeder
Open

Remove Aqara Pet Feeder "legacy" quirks from ZHA#883
iamjoshk wants to merge 10 commits into
zigpy:devfrom
iamjoshk:iamjoshk-aqarapetfeeder

Conversation

@iamjoshk

@iamjoshk iamjoshk commented Sep 1, 2026

Copy link
Copy Markdown

Fixes #705
Dependent on PR for Aqara pet feeder quirk v2: updated PR for v2 migration: zigpy/zha-device-handlers#5296

This PR removes the "legacy" quirks from ZHA for the Aqara Pet Feeder.

  • Binary Sensor AqaraPetFeederErrorDetected class
  • Button AqaraPetFeederFeedButton class
  • Number AqaraPetFeederServingSize and AqaraPetFeederPortionWeight classes
  • Select AqaraFeedingMode and AqaraPetFeederMode classes
  • Sensor AqaraFeedingSource, AqaraPetFeederLastFeedingSource, AqaraPetFeederLastFeedingSize, and AqaraPetFeederPortionsDispensed classes
  • Switch AqaraPetFeederLEDIndicator and AqaraPetFeederChildLock classes
  • Virtual AqaraFeederInit class

Also removes the now unused import for UnitOfMass in number init and sensor init.

Remove AqaraPetFeederErrorDetected
Remove AqaraPetFeederFeedButton
Remove AqaraPetFeederPortionWeight and AqaraPetFeederServingSize
Remove AqaraFeedingSource, AqaraPetFeederWeightDispensed, AqaraPetFeederPortionsDispensed, AqaraPetFeederLastFeedingSize, and AqaraPetFeederLastFeedingSource
Remove AqaraPetFeederChildLock and AqaraPetFeederLEDIndicator
Remove AqaraPetFeederMode and AqaraFeedingMode
Remove AqaraFeederInit
@codecov

codecov Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.16%. Comparing base (28272e9) to head (927a2f6).
⚠️ Report is 1 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #883      +/-   ##
==========================================
- Coverage   97.19%   97.16%   -0.03%     
==========================================
  Files          57       57              
  Lines       10560    10457     -103     
==========================================
- Hits        10264    10161     -103     
  Misses        296      296              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@iamjoshk
iamjoshk marked this pull request as ready for review September 8, 2026 14:55
Copilot AI lite review requested due to automatic review settings September 8, 2026 14:55

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

It is a cross-repo coordinated change with potential user-visible breakage if merged/released out of sync with the dependent quirks v2 migration in zha-device-handlers.

Pull request overview

Removes ZHA’s built-in (“legacy”) Aqara Pet Feeder (ACN001) platform entities and init configuration so the device is handled solely via the quirks v2 implementation in zha-device-handlers.

Changes:

  • Removed legacy entity classes for the Aqara Pet Feeder across binary_sensor/button/number/select/sensor/switch platforms.
  • Removed the Aqara Pet Feeder virtual init entity (AqaraFeederInit) and its cluster attribute startup configuration.
  • Cleaned up now-unused UnitOfMass imports where they were only used by the removed feeder entities.
File summaries
File Description
zha/application/platforms/virtual.py Removes the Aqara Pet Feeder virtual init entity and its AQARA_OPPLE_CLUSTER attribute config.
zha/application/platforms/switch.py Removes legacy feeder LED indicator and child lock switch entities.
zha/application/platforms/sensor/init.py Removes legacy feeder sensors/enums and drops the related UnitOfMass import.
zha/application/platforms/select.py Removes legacy feeder feeding mode enum/select entity.
zha/application/platforms/number/init.py Removes legacy feeder number entities and drops the related UnitOfMass import.
zha/application/platforms/button/init.py Removes the legacy feeder “Feed” button entity.
zha/application/platforms/binary_sensor/init.py Removes the legacy feeder “error detected” binary sensor entity.
Review details
  • Files reviewed: 7/7 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the 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.

Add new enum member to AqaraFeedingSource

2 participants