Skip to content

Conversation

@alams154
Copy link
Contributor

Add D225 support to python-kasa.

@codecov
Copy link

codecov bot commented Oct 29, 2025

Codecov Report

❌ Patch coverage is 95.83333% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.75%. Comparing base (f30f38b) to head (f17868d).

Files with missing lines Patch % Lines
kasa/smartcam/modules/battery.py 93.93% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1596      +/-   ##
==========================================
+ Coverage   92.73%   92.75%   +0.01%     
==========================================
  Files         157      157              
  Lines        9634     9670      +36     
  Branches      976      981       +5     
==========================================
+ Hits         8934     8969      +35     
- Misses        499      501       +2     
+ Partials      201      200       -1     

☔ View full report in Codecov by Sentry.
📢 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.

Copy link
Member

@rytilahti rytilahti left a comment

Choose a reason for hiding this comment

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

Thanks for the PR! When adding new fixtures, please avoid doing changes elsewhere in the library if they are not very, very minor changes to adjust the library to make it work with the device in question. Instead, create a separate PRs, this will help to keep the git history clean.

@alams154
Copy link
Contributor Author

Hi, thanks for the information. I've reverted the library changes. The fixture files can't be generated without some of those bigger library changes so I can open another PR for those. It throws "Unsupported device {discovery_result.ip} of type {type_} with no encryption type".

@rytilahti
Copy link
Member

I see, thanks for the clean up! Is it possible to do anything with the device before we get the other changes in? Just asking if this would be ready for merging after a review, or would it be better to wait for the follow up PR(s) before updating the readme?

If the only issue is the fixture generation, we could go and move forward to merge this already.

@alams154
Copy link
Contributor Author

I think we could proceed with merging the fixtures already.

There are still issues with fixture generation and running the kasa command without extra options (says "Unable to create device for <DEVICE_IP>") but I think we can address those in the next PR (#1602).

@rytilahti rytilahti added the new device New device supported due to fixture being added label Oct 29, 2025
@rytilahti rytilahti enabled auto-merge (squash) October 29, 2025 22:07
@rytilahti rytilahti disabled auto-merge October 29, 2025 22:15
@rytilahti
Copy link
Member

Looks like the tests are failing, would it be possible to add to this PR only the minimal changes that make them pass?

@alams154
Copy link
Contributor Author

I don't think there is a minimal change since it affects discovery and then when that change is implemented, it causes more tests to fail regarding the battery which requires changes to the battery test.

What would be the best way to proceed now?

@alams154
Copy link
Contributor Author

alams154 commented Nov 5, 2025

Maybe we merge #1602 first and then merge this?

@rytilahti
Copy link
Member

Yes, that makes sense, I think. Would you mind taking care of cleaning up the PR to add only the necessary changes? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new device New device supported due to fixture being added

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants