FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Stabilise on_since value for smart devices by sdb9696 · Pull Request #1144 · python-kasa/python-kasa · GitHub

Repository navigation

Stabilise on_since value for smart devices - #1144

Merged
sdb9696 merged 8 commits into
masterfrom
fix/on_since
Oct 2, 2024
Merged

sdb9696 merged 8 commits into
masterfrom
fix/on_since

Conversation

sdb9696 commented Sep 30, 2024

Copy link
Copy Markdown
Contributor

Should address HA issue 126852.

It's difficult to know for certain how many seconds to set this to but I suspect the variation is just 1 second.

codecov Bot commented Sep 30, 2024 •
edited
Loading

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 95.23810% with 1 line in your changes missing coverage. Please review.

Project coverage is 92.59%. Comparing base (81e2685) to head (993fc51).
Report is 195 commits behind head on master.

Files with missing lines Patch % Lines
kasa/iot/iotdevice.py 87.50% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1144   +/-   ##
=======================================
  Coverage   92.59%   92.59%           
=======================================
  Files          96       96           
  Lines        6104     6119   +15     
  Branches     1512     1514    +2     
=======================================
+ Hits         5652     5666   +14     
  Misses        354      354           
- Partials       98       99    +1     

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

Comment thread kasa/smart/smartdevice.py
sdb9696 added the bug Something isn't working label Oct 1, 2024
sdb9696 added this to the 0.7.5 milestone Oct 1, 2024

rytilahti left a comment •
edited
Loading

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Just a minor nit on the docstring wording, but otherwise this looks good!
I have been running this now for four hours (checking on an iot device though, so please update the PR title), with four changes on the current homeassistant vs. none when using this PR.

Comment thread kasa/device.py Outdated
sdb9696 merged commit 1fcf3e4 into master Oct 2, 2024
sdb9696 deleted the fix/on_since branch October 2, 2024 14:04
sdb9696 mentioned this pull request Oct 8, 2024
sdb9696 added a commit that referenced this pull request Oct 8, 2024
## [0.7.5](https://github.com/python-kasa/python-kasa/tree/0.7.5) (2024-10-08)

[Full Changelog](0.7.4...0.7.5)

**Release summary:**

- Fix for KP303 on Firmware 1.0.6
- Fix for `on_since` value jitter
- Various maintenance items

**Breaking changes:**

- Make iot time timezone aware [\#1147](#1147) (@sdb9696)

**Fixed bugs:**

- Use tzinfo in time constructor instead of astime for iot devices [\#1158](#1158) (@sdb9696)
- Send empty dictionary instead of null for iot queries [\#1145](#1145) (@sdb9696)
- Stabilise on\_since value for smart devices [\#1144](#1144) (@sdb9696)
- parse\_pcap\_klap: require source host [\#1137](#1137) (@rytilahti)
- parse\_pcap\_klap: use request\_uri for matching the response [\#1136](#1136) (@rytilahti)


**Project maintenance:**

- Cache zoneinfo for smart devices [\#1156](#1156) (@sdb9696)
- Correctly define SmartModule.call as an async function [\#1148](#1148) (@sdb9696)
- Remove async magic patch from tests [\#1146](#1146) (@sdb9696)
- Move feature initialization from \_\_init\_\_ to \_initialize\_features [\#1140](#1140) (@rytilahti)
pillarsdotnet pushed a commit to pillarsdotnet/python-kasa that referenced this pull request Oct 22, 2026
Caches the `on_since` value to prevent jitter caused by the device calculations.
pillarsdotnet pushed a commit to pillarsdotnet/python-kasa that referenced this pull request Oct 22, 2026
## [0.7.5](https://github.com/python-kasa/python-kasa/tree/0.7.5) (2024-10-08)

[Full Changelog](python-kasa/python-kasa@0.7.4...0.7.5)

**Release summary:**

- Fix for KP303 on Firmware 1.0.6
- Fix for `on_since` value jitter
- Various maintenance items

**Breaking changes:**

- Make iot time timezone aware [\python-kasa#1147](python-kasa#1147) (@sdb9696)

**Fixed bugs:**

- Use tzinfo in time constructor instead of astime for iot devices [\python-kasa#1158](python-kasa#1158) (@sdb9696)
- Send empty dictionary instead of null for iot queries [\python-kasa#1145](python-kasa#1145) (@sdb9696)
- Stabilise on\_since value for smart devices [\python-kasa#1144](python-kasa#1144) (@sdb9696)
- parse\_pcap\_klap: require source host [\python-kasa#1137](python-kasa#1137) (@rytilahti)
- parse\_pcap\_klap: use request\_uri for matching the response [\python-kasa#1136](python-kasa#1136) (@rytilahti)


**Project maintenance:**

- Cache zoneinfo for smart devices [\python-kasa#1156](python-kasa#1156) (@sdb9696)
- Correctly define SmartModule.call as an async function [\python-kasa#1148](python-kasa#1148) (@sdb9696)
- Remove async magic patch from tests [\python-kasa#1146](python-kasa#1146) (@sdb9696)
- Move feature initialization from \_\_init\_\_ to \_initialize\_features [\python-kasa#1140](python-kasa#1140) (@rytilahti)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL