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

tests: add type annotations to top-level test files by ZeliardM · Pull Request #1688 · python-kasa/python-kasa · GitHub

Repository navigation

tests: add type annotations to top-level test files - #1688

Merged
rytilahti merged 4 commits into
python-kasa:masterfrom
ZeliardM:tests/toplevel-type-annotations
Oct 4, 2026
Merged

rytilahti merged 4 commits into
python-kasa:masterfrom
ZeliardM:tests/toplevel-type-annotations

Conversation

ZeliardM commented Apr 7, 2026 •
edited
Loading

Copy link
Copy Markdown
Collaborator

Summary

Add type annotations (parameter types and -> None return types) to all top-level test functions across 22 test files. This enables mypy to check test function bodies, catching type errors that were previously hidden.

Type annotations added

  • -> None return types on void test functions (only on functions that don't return values or yield)
  • Parameter type annotations from common patterns: dev: Device, mocker: MockerFixture, runner: CliRunner, etc.
  • Missing imports for newly-used types: MockerFixture, Module, URL, SmartProtocol, etc.

Pre-existing type issues fixed (exposed by new annotations)

  • Use isinstance narrowing for Device | Module union types in test_feature.py
  • Add None-safety assertions for optional values (alias, encrypt_type, etc.)
  • Build CLI args conditionally when encrypt_type is None (SMARTCAM fixtures)
  • Fix int-to-str in CLI argument lists (--discovery-timeout 0 → "0")
  • Add explicit type annotations for variable assignments to avoid inference conflicts
  • Use cast for intentional type mismatches in serialization tests
  • Add module.__package__ is not None guard in test_device.py

Pre-existing bugs fixed

  • Fix _mock_response.read() return type from None to bytes in test_httpclient.py
  • Fix chained comparison bug in fakeprotocol_smart._edit_preset_rules: "states" not in info[...] is None always evaluated false due to Python's chained comparison semantics; replaced with .get("states") is None

Annotations intentionally omitted

  • dev parameter in test_command_with_child (uses dynamic dev.__class__ as base class)
  • dev parameter in test_all_binary_states (skipped test using strip-specific is_on.items() API)

Out of scope

Files changed (22)

tests/conftest.py, tests/device_fixtures.py, tests/discovery_fixtures.py, tests/fakeprotocol_iot.py, tests/fakeprotocol_smart.py, tests/fakeprotocol_smartcam.py, tests/fixtureinfo.py, tests/test_bulb.py, tests/test_childdevice.py, tests/test_cli.py, tests/test_common_modules.py, tests/test_device.py, tests/test_device_factory.py, tests/test_device_type.py, tests/test_deviceconfig.py, tests/test_devtools.py, tests/test_discovery.py, tests/test_feature.py, tests/test_httpclient.py, tests/test_plug.py, tests/test_readme_examples.py, tests/test_strip.py

Merge order

This is PR 9 of 9 in the test modernization series. Must merge last — has file overlaps with #1677 and #1683.

Order PR Scope
1 #1677 Tests: cleanup and fixes
2 #1681 CI: pin GitHub Actions to SHA
3 #1682 Docs: modernize docstrings
4 #1683 Tests: centralize session cleanup
5 #1684 Tests: transport type annotations
6 #1685 Tests: IoT type annotations
7 #1686 Tests: Smart type annotations
8 #1687 Tests: CLI/protocols/smartcam type annotations
9 #1688 Tests: top-level type annotations

Merge note: Two trivial context conflicts when merging after #1677 + #1683:

  1. tests/conftest.py: Keep tests: centralize transport and session cleanup in conftest #1683's _close_transport_and_http_sessions fixture and this PR's type annotation on load_fixture(foldername: str, filename: str)
  2. tests/test_device.py: Keep tests: fix typos, child device subtype, CLI patch path, and deprecation test logic #1677's will_warn = is_expected or attribute_name in deprecated_warns_before_attribute_error and this PR's type annotations + if is_expected and will_raise: condition

Verification

  • mypy: 0 errors across all 22 files
  • pre-commit: all hooks pass (ruff, ruff-format, mypy)
  • pytest: all test_cli.py tests pass (6,697 passed, 194 skipped)
  • Full test suite passes after sequential merge of all 9 PRs (10,656 passed, 194 skipped)

Copilot AI review requested due to automatic review settings April 7, 2026 03:20

Copilot AI left a comment

Copy link
Copy Markdown

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

Pull request overview

This PR adds explicit type annotations to top-level test functions (and related helpers) across the test suite so mypy can type-check test bodies and surface previously-hidden type issues.

Changes:

  • Add parameter/return type annotations (-> None, MockerFixture, CliRunner, Device, etc.) across many tests and fixtures.
  • Apply small test-side fixes exposed by typing (e.g., None assertions, cast(...), and stringifying CLI args).
  • Refine some test helpers/fake protocols with additional typing and minor logic adjustments.

Reviewed changes

Copilot reviewed 22 out of 22 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
tests/conftest.py Annotates common test helpers and pytest hooks to improve type checking.
tests/device_fixtures.py Adds typing to fixture utilities and the main dev fixture.
tests/discovery_fixtures.py Adds typing to discovery fixtures and patch helpers.
tests/fakeprotocol_iot.py Adds typing to fake IOT protocol/transport helpers.
tests/fakeprotocol_smart.py Adds typing to fake SMART protocol helpers and setters.
tests/fakeprotocol_smartcam.py Adds typing to fake SMARTCAM protocol/transport helpers.
tests/fixtureinfo.py Adds typing to fixture info utilities and fixture.
tests/test_bulb.py Adds -> None / parameter annotations to bulb tests.
tests/test_childdevice.py Adds -> None / parameter annotations to child-device tests.
tests/test_cli.py Adds typing to CLI tests and fixes a few typed CLI arg cases.
tests/test_common_modules.py Adds -> None / parameter annotations to common module tests.
tests/test_device.py Adds typing to device tests and helper utilities.
tests/test_device_factory.py Adds typing to factory/connect tests and adjusts http client access typing.
tests/test_device_type.py Adds -> None return annotation to the device type test.
tests/test_deviceconfig.py Adds typing to serialization/deserialization tests and uses cast where intentional.
tests/test_devtools.py Adds -> None / parameter annotations to devtools tests.
tests/test_discovery.py Adds -> None / parameter annotations to discovery tests and helper stubs.
tests/test_feature.py Adds typing and narrowing for feature tests (including union/container handling).
tests/test_httpclient.py Adds typing to http client tests and switches to yarl.URL for HttpClient.post.
tests/test_plug.py Adds -> None return annotations to plug tests.
tests/test_readme_examples.py Adds typing for doctest-driving tests and mocker usage.
tests/test_strip.py Adds typing and None-safety assertions for strip/children tests.
Comments suppressed due to low confidence (1)

tests/fakeprotocol_smartcam.py:140

  • FakeSmartCamTransport._get_param_set_value types value as dict, but the call site passes section_value from parsed request params, which can be non-dict values (e.g., bool/int/str). This annotation is too narrow; widen it (e.g., Any/object) or use a generic type variable that matches the actual setter values.
    @staticmethod
    def _get_param_set_value(info: dict, set_keys: list[str], value: dict) -> None:
        cifp = info.get(CHILD_INFO_FROM_PARENT)

        for key in set_keys[:-1]:
            info = info[key]
        info[set_keys[-1]] = value

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/test_httpclient.py Outdated
Comment thread tests/test_httpclient.py
Comment thread tests/test_feature.py Outdated
Comment thread tests/test_discovery.py Outdated
Comment thread tests/fakeprotocol_smart.py Outdated
Comment thread tests/test_discovery.py Outdated

codecov Bot commented Apr 7, 2026 •
edited
Loading

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.39%. Comparing base (eed64fe) to head (4da4879).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1688   +/-   ##
=======================================
  Coverage   93.39%   93.39%           
=======================================
  Files         159      159           
  Lines       10080    10080           
  Branches     1038     1038           
=======================================
  Hits         9414     9414           
  Misses        472      472           
  Partials      194      194           

☔ 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.

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days.
If you are the author of this PR, please leave a comment if you want to keep it open. Also, please rebase your PR onto the latest dev branch to ensure that it's up to date with the latest changes.
Thank you for your contribution!

github-actions Bot added the stale label Jul 7, 2026

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

It is really great to see type hints getting added also to the test code, thanks a lot for doing the grunt work @ZeliardM! Do you have a plan to flip the switch to start enforcing these in the pre-commit/CI?

Feel free to merge as you wish, I left a couple of comments behind for potential improvements, but this is good to go already as it is.

One remaining question is, do you want to create a PR to also start enforcing types via CI for tests, too?

Comment thread tests/conftest.py Outdated
Comment thread tests/fakeprotocol_iot.py Outdated
Comment thread tests/test_common_modules.py Outdated
Comment thread tests/test_deviceconfig.py Outdated
Comment thread tests/test_feature.py Outdated
github-actions Bot removed the stale label Jul 8, 2026
ZeliardM force-pushed the tests/toplevel-type-annotations branch from 64aabc8 to 2fb2bb4 Compare July 10, 2026 14:38
rytilahti force-pushed the tests/toplevel-type-annotations branch from 2fb2bb4 to b94883d Compare September 18, 2026 16:35
Add type annotations (parameter types and -> None return types) to all
top-level test functions across 22 test files. This enables mypy to check
test function bodies, catching type errors that were previously hidden.

Key changes:
- Add -> None return types to void test functions
- Add parameter type annotations (Device, MockerFixture, CliRunner, etc.)
- Add missing imports (MockerFixture, Module, URL, SmartProtocol, etc.)
- Fix pre-existing type issues exposed by the new annotations:
  - Use isinstance narrowing for Device | Module union types
  - Add None-safety assertions for optional values
  - Fix int-to-str in CLI argument lists
  - Add explicit type annotations for variable assignments
  - Use cast for intentional type mismatches in tests
- Remove dev: Device annotations from functions using dynamic class
  inheritance or strip-specific APIs incompatible with Device type
- Fix test_credentials: build CLI args conditionally when encrypt_type
  is None (SMARTCAM fixtures have no encrypt_type)
- Add missing -> None to test_httpclient_errors, test_feature_value_container,
  test_discover_try_connect_all
- Fix _mock_response.read() return type from None to bytes
- Fix chained comparison bug in fakeprotocol_smart._edit_preset_rules:
  'not in ... is None' always evaluates false; use .get() instead
rytilahti force-pushed the tests/toplevel-type-annotations branch from b94883d to 4da4879 Compare October 4, 2026 14:32
rytilahti enabled auto-merge (squash) October 4, 2026 14:33
rytilahti merged commit b36c795 into python-kasa:master Oct 4, 2026
21 of 22 checks passed
rytilahti added the maintenance Project improvements and maintenance label Oct 4, 2026
rytilahti mentioned this pull request Oct 4, 2026
rytilahti added a commit that referenced this pull request Oct 4, 2026
## [0.11.0](https://github.com/python-kasa/python-kasa/tree/0.11.0)
(2026-10-04)

[Full
Changelog](0.10.2...0.11.0)

**Release summary:**

This is a huge and long overdue release, coming more than a year and a
half after the previous one.
Hopefully the next one follows sooner, as the TPAP transport (which did
not make it into this release) is used more and more on newer devices.

This release brings broader camera support, new modules for lights,
vacuums and cameras, and many connectivity fixes for newer firmware
versions. Some other highlights:
- Improved Tapo camera support: login version 3, presets, wifi handling,
last alert detection, and more robust authentication and discovery.
- Selective room cleaning for robot vacuums.
- Configurable light strip length via the new strip segment module, and
an exposed light transition state change flag.
- Basic HomeKit module for Kasa (iot) devices.
- Energy monitoring V2 support (S515D).
- Better hub and thermostat state reporting (hold, summer mode, low
battery).
- Connection fixes for newer Tapo firmware and older SSL devices, plus
KLAP v2 for iot devices.
- More resilient time handling, with failover and UTC fallback for iot
devices.
- Python 3.14 is now supported.
- Inclusion of fixtures for 29 devices or firmware versions, including
the Tapo C460, C200 and C101 cameras and the KH100 hub with KE100/KE110
thermostats.

**Thank you to all contributors!**

A big thank you to everyone who contributed to this release, whether
through code, device fixtures, bug reports or testing.

Special thanks to @ZeliardM for a huge effort on both features and
project maintenance, including but not limited to:
- Features like the HomeKit module for iot devices, iot time module
failover, wifi handling and credential improvements for cameras, Tapo
login version 3, and V2 energy monitoring for S515D.
- A lot of necessary maintenance work including type annotations and
cleanups throughout the test suite, modernized docstrings, CI hardening
with SHA-pinned actions, and many bug fixes. This helps us to keep the
library maintainable and open to new contributions.

A warm welcome to our new contributors, with special thanks to those who
contributed improvements and fixes:
- @alams154: discovery on port 20004
- @bluntman001: iot device classification fix
- @bm1549: KLAP v2 transport for iot devices
- @darylldelfin: cipher support for newer Tapo firmware
- @davidefiocco: vacuum mop water level fix
- @epg-pers: selective room cleaning for vacuums
- @freeKC: camera discovery and authentication fixes
- @gpongelli: extended camera detection
- @Ikstar: KL420 color temperature range
- @juherr: last alert detection module for cameras, camera error codes
and a C200 fixture
- @kad: SSL connections to older devices
- @KaloyanNaumov: multi-request timeout handling
- @loganrosen: KL400L5 color temperature range
- @markvanpraet: Tapo C460 support and camera battery fix
- @monteccarlos: iot timezone mapping fix
- @mrwogu: preset support for Tapo cameras
- @nopoz: strip segment module, light transition flag and credentials
hash fix
- @tk1475: UTC fallback for unset iot device clocks
- @wh1t3f1r3: non-retryable network error handling

Thanks also to our new contributors who provided device fixtures to help
future development efforts: @emanueleg, @fantandrea, @HarryPehkonen,
@ijaron, @Krotu, @LostLuma, @mjbohr and @TheLinuxGuy.

**This release in numbers:**

- 68 merged pull requests from 29 contributors, 27 of them first-time
contributors
- 8 new modules
- 29 new device fixtures
- 203 files changed, with 25,199 lines added and 2,585 removed


**Implemented enhancements:**

- \[Feature Request\] C220 camera line crossing detection on-off switch
[\#1551](#1551)
- SslAesTransport: handshake again when a camera answers 401 to
passthrough
[\#1771](#1771) (@freeKC)
- Add LastAlertDetection module for smartcam devices
[\#1762](#1762) (@juherr)
- Add KL420 to TPLINK\_KELVIN color temperature ranges
[\#1757](#1757) (@Ikstar)
- Do not authenticate with a credentials\_hash from a different
transport [\#1749](#1749)
(@nopoz)
- Expose the light transition state change flag
[\#1745](#1745) (@nopoz)
- Add strip segment module for configurable light strip length
[\#1744](#1744) (@nopoz)
- Add KL400L5 color temperature range
[\#1719](#1719)
(@loganrosen)
- Update smartcam credential handling and tests
[\#1664](#1664)
(@ZeliardM)
- Add support for V2 Energy Monitoring for S515D
[\#1663](#1663)
(@ZeliardM)
- Add selective room cleaning to vacuum clean module
[\#1660](#1660)
(@epg-pers)
- New Wi-Fi handling for SMARTCAM devices
[\#1639](#1639)
(@ZeliardM)
- Add support for tapo login\_version 3 in sslaestransport
[\#1638](#1638)
(@ZeliardM)
- Add preset support for Tapo cameras
[\#1615](#1615) (@mrwogu)
- Add python 3.14 to supported versions
[\#1599](#1599)
(@rytilahti)
- Add discovery port 20004
[\#1595](#1595)
(@alams154)
- Implement IOT Time Module Failover
[\#1583](#1583)
(@ZeliardM)
- Add bare bones homekit module for iot devices
[\#1566](#1566)
(@ZeliardM)
- Extend smartcam detection support
[\#1552](#1552)
(@gpongelli)

**Fixed bugs:**

- Time module unavailable for waterleak sensor
[\#1613](#1613)
- 'No time zone found with key EST' in debian 13
[\#1579](#1579)
- Discovery: accept cameras that only send the encrypt\_type list
[\#1770](#1770) (@freeKC)
- Classify IOT devices via sysinfo regardless of transport \(fixes
\#1740\) [\#1769](#1769)
(@bluntman001)
- Fall back to UTC for iot time when the device clock is not set
[\#1768](#1768) (@tk1475)
- Add UNKNOWN\_USERNAME \(-60502\) camera error code
[\#1761](#1761) (@juherr)
- Disable multi requests on timeout during multi-request
[\#1759](#1759)
(@KaloyanNaumov)
- Add ECDHE-RSA-AES256 cipher for newer Tapo firmware
[\#1755](#1755)
(@darylldelfin)
- Map iot timezone index 18 to America/New\_York instead of EST
[\#1743](#1743)
(@monteccarlos)
- fix: use KLAP v2 transport for IOT devices with login version 2
[\#1731](#1731) (@bm1549)
- Add ENETUNREACH to non-retryable errors in XorTransport
[\#1668](#1668)
(@wh1t3f1r3)
- Fix mop set\_waterlevel sending setCleanAttr without type field
[\#1667](#1667)
(@davidefiocco)
- Fix SMARTCAM Time module and update tests
[\#1659](#1659)
(@ZeliardM)
- Fix camera login version in CLI
[\#1658](#1658)
(@ZeliardM)
- Allow SSL connections to older devices
[\#1654](#1654) (@kad)
- waterleaksensor: use parent's Time for alert timestamp
[\#1614](#1614)
(@rytilahti)
- Add hold state to thermostatstate
[\#1609](#1609)
(@rytilahti)
- Fix thermostat idle reporting on low battery
[\#1598](#1598)
(@rytilahti)
- Add shutdown \(summer mode\) to thermostatstate
[\#1588](#1588)
(@rytilahti)
- Fix iotstrip child device time handling
[\#1584](#1584)
(@ZeliardM)

**Added support for devices:**

- Add C200 device fixture
[\#1760](#1760) (@juherr)
- Add P125M fixture for firmware 1.4.4
[\#1746](#1746)
(@HarryPehkonen)
- Add fixtures for KH100, KE100 and KE110 and simulate TRV states
[\#1726](#1726) (@Krotu)
- Add L530EA\(EU\) device fixture
[\#1694](#1694)
(@ZeliardM)
- Add C101 test fixture
[\#1673](#1673) (@ijaron)
- Add LB130\(US\) device fixture
[\#1669](#1669)
(@ZeliardM)
- Add KL110B\(UN\) device fixture
[\#1657](#1657)
(@ZeliardM)
- Add TS15\(US\) device fixture
[\#1649](#1649)
(@ZeliardM)
- Add Tapo C460 support
[\#1645](#1645)
(@markvanpraet)
- Add P105\(US\) device fixture
[\#1644](#1644)
(@ZeliardM)
- Add L430C\(EU\) device fixture
[\#1643](#1643)
(@ZeliardM)
- Add L430P\(EU\) device fixture
[\#1607](#1607)
(@LostLuma)
- Add S500\(US\)\_1.0\_1.2.0 fixture
[\#1569](#1569)
(@ZeliardM)
- Add device fixture for P316M\(US\)
[\#1568](#1568)
(@TheLinuxGuy)
- Add L535E\(EU\) 3.0 1.1.8 fixture
[\#1545](#1545)
(@fantandrea)
- Adding KL400L10\(US\)\_1.0\_1.0.10 fixture
[\#1539](#1539) (@mjbohr)
- Add TP10\(IT\) 1.0 1.2.5 fixture
[\#1538](#1538)
(@emanueleg)
- Add LB100\(US\)\_1.0\_1.8.11 fixture file
[\#1515](#1515)
(@ZeliardM)
- Add KS225\(US\)\_1.0\_1.1.1 and L930-5\(EU\)\_1.0\_1.2.5
[\#1509](#1509)
(@ZeliardM)

**Documentation updates:**

- How to hash credentials to make use of --credentials-hash flag?
[\#1517](#1517)
- docs: modernize docstrings across the repository
[\#1682](#1682)
(@ZeliardM)
- Add a note to emeter guide being kasa-only
[\#1512](#1512)
(@rytilahti)

**Project maintenance:**

- tests: add type annotations to top-level test files
[\#1688](#1688)
(@ZeliardM)
- tests: add type annotations to CLI, protocol, and smartcam tests
[\#1687](#1687)
(@ZeliardM)
- tests: add type annotations to Smart tests
[\#1686](#1686)
(@ZeliardM)
- tests: add type annotations to IoT tests
[\#1685](#1685)
(@ZeliardM)
- tests: add type annotations to transport tests
[\#1684](#1684)
(@ZeliardM)
- tests: centralize transport and session cleanup in conftest
[\#1683](#1683)
(@ZeliardM)
- ci: pin all GitHub Actions to SHA hashes and update versions
[\#1681](#1681)
(@ZeliardM)
- tests: fix typos, child device subtype, CLI patch path, and
deprecation test logic
[\#1677](#1677)
(@ZeliardM)
- Update GitHub Workflows and Actions
[\#1622](#1622)
(@ZeliardM)
- Use log-level debug for smartdevice query error reporting
[\#1587](#1587)
(@rytilahti)
- Use Device instead of SmartDevice where feasible
[\#1585](#1585)
(@ZeliardM)

**Closed issues:**

- Python 3.14 Support
[\#1597](#1597)
- HS300 Child State - Time Module Error
[\#1445](#1445)
rytilahti mentioned this pull request Oct 4, 2026
rytilahti added a commit that referenced this pull request Oct 4, 2026
## [0.11.0.1](https://github.com/python-kasa/python-kasa/tree/0.11.0.1)
(2026-10-04)

[Full
Changelog](0.10.2...0.11.0.1)

**Release summary:**

*Note: 0.11.0 was tagged but never published to PyPI due to a packaging
issue. 0.11.0.1 contains the same changes plus a fix for the release
workflow.*

This is a huge and long overdue release, coming more than a year and a
half after the previous one.
Hopefully the next one follows sooner, as the TPAP transport (which did
not make it into this release) is used more and more on newer devices.

This release brings broader camera support, new modules for lights,
vacuums and cameras, and many connectivity fixes for newer firmware
versions. Some other highlights:
- Improved Tapo camera support: login version 3, presets, wifi handling,
last alert detection, and more robust authentication and discovery.
- Selective room cleaning for robot vacuums.
- Configurable light strip length via the new strip segment module, and
an exposed light transition state change flag.
- Basic HomeKit module for Kasa (iot) devices.
- Energy monitoring V2 support (S515D).
- Better hub and thermostat state reporting (hold, summer mode, low
battery).
- Connection fixes for newer Tapo firmware and older SSL devices, plus
KLAP v2 for iot devices.
- More resilient time handling, with failover and UTC fallback for iot
devices.
- Python 3.14 is now supported.
- Inclusion of fixtures for 29 devices or firmware versions, including
the Tapo C460, C200 and C101 cameras and the KH100 hub with KE100/KE110
thermostats.

**Thank you to all contributors!**

A big thank you to everyone who contributed to this release, whether
through code, device fixtures, bug reports or testing.

Special thanks to @ZeliardM for a huge effort on both features and
project maintenance, including but not limited to:
- Features like the HomeKit module for iot devices, iot time module
failover, wifi handling and credential improvements for cameras, Tapo
login version 3, and V2 energy monitoring for S515D.
- A lot of necessary maintenance work including type annotations and
cleanups throughout the test suite, modernized docstrings, CI hardening
with SHA-pinned actions, and many bug fixes. This helps us to keep the
library maintainable and open to new contributions.

A warm welcome to our new contributors, with special thanks to those who
contributed improvements and fixes:
- @alams154: discovery on port 20004
- @bluntman001: iot device classification fix
- @bm1549: KLAP v2 transport for iot devices
- @darylldelfin: cipher support for newer Tapo firmware
- @davidefiocco: vacuum mop water level fix
- @epg-pers: selective room cleaning for vacuums
- @freeKC: camera discovery and authentication fixes
- @gpongelli: extended camera detection
- @Ikstar: KL420 color temperature range
- @juherr: last alert detection module for cameras, camera error codes
and a C200 fixture
- @kad: SSL connections to older devices
- @KaloyanNaumov: multi-request timeout handling
- @loganrosen: KL400L5 color temperature range
- @markvanpraet: Tapo C460 support and camera battery fix
- @monteccarlos: iot timezone mapping fix
- @mrwogu: preset support for Tapo cameras
- @nopoz: strip segment module, light transition flag and credentials
hash fix
- @tk1475: UTC fallback for unset iot device clocks
- @wh1t3f1r3: non-retryable network error handling

Thanks also to our new contributors who provided device fixtures to help
future development efforts: @emanueleg, @fantandrea, @HarryPehkonen,
@ijaron, @Krotu, @LostLuma, @mjbohr and @TheLinuxGuy.

**This release in numbers:**

- 68 merged pull requests from 29 contributors, 27 of them first-time
contributors
- 8 new modules
- 29 new device fixtures
- 203 files changed, with 25,199 lines added and 2,585 removed


**Implemented enhancements:**

- \[Feature Request\] C220 camera line crossing detection on-off switch
[\#1551](#1551)
- SslAesTransport: handshake again when a camera answers 401 to
passthrough
[\#1771](#1771) (@freeKC)
- Add LastAlertDetection module for smartcam devices
[\#1762](#1762) (@juherr)
- Add KL420 to TPLINK\_KELVIN color temperature ranges
[\#1757](#1757) (@Ikstar)
- Do not authenticate with a credentials\_hash from a different
transport [\#1749](#1749)
(@nopoz)
- Expose the light transition state change flag
[\#1745](#1745) (@nopoz)
- Add strip segment module for configurable light strip length
[\#1744](#1744) (@nopoz)
- Add KL400L5 color temperature range
[\#1719](#1719)
(@loganrosen)
- Update smartcam credential handling and tests
[\#1664](#1664)
(@ZeliardM)
- Add support for V2 Energy Monitoring for S515D
[\#1663](#1663)
(@ZeliardM)
- Add selective room cleaning to vacuum clean module
[\#1660](#1660)
(@epg-pers)
- New Wi-Fi handling for SMARTCAM devices
[\#1639](#1639)
(@ZeliardM)
- Add support for tapo login\_version 3 in sslaestransport
[\#1638](#1638)
(@ZeliardM)
- Add preset support for Tapo cameras
[\#1615](#1615) (@mrwogu)
- Add python 3.14 to supported versions
[\#1599](#1599)
(@rytilahti)
- Add discovery port 20004
[\#1595](#1595)
(@alams154)
- Implement IOT Time Module Failover
[\#1583](#1583)
(@ZeliardM)
- Add bare bones homekit module for iot devices
[\#1566](#1566)
(@ZeliardM)
- Extend smartcam detection support
[\#1552](#1552)
(@gpongelli)

**Fixed bugs:**

- Time module unavailable for waterleak sensor
[\#1613](#1613)
- 'No time zone found with key EST' in debian 13
[\#1579](#1579)
- Discovery: accept cameras that only send the encrypt\_type list
[\#1770](#1770) (@freeKC)
- Classify IOT devices via sysinfo regardless of transport \(fixes
\#1740\) [\#1769](#1769)
(@bluntman001)
- Fall back to UTC for iot time when the device clock is not set
[\#1768](#1768) (@tk1475)
- Add UNKNOWN\_USERNAME \(-60502\) camera error code
[\#1761](#1761) (@juherr)
- Disable multi requests on timeout during multi-request
[\#1759](#1759)
(@KaloyanNaumov)
- Add ECDHE-RSA-AES256 cipher for newer Tapo firmware
[\#1755](#1755)
(@darylldelfin)
- Map iot timezone index 18 to America/New\_York instead of EST
[\#1743](#1743)
(@monteccarlos)
- fix: use KLAP v2 transport for IOT devices with login version 2
[\#1731](#1731) (@bm1549)
- Add ENETUNREACH to non-retryable errors in XorTransport
[\#1668](#1668)
(@wh1t3f1r3)
- Fix mop set\_waterlevel sending setCleanAttr without type field
[\#1667](#1667)
(@davidefiocco)
- Fix SMARTCAM Time module and update tests
[\#1659](#1659)
(@ZeliardM)
- Fix camera login version in CLI
[\#1658](#1658)
(@ZeliardM)
- Allow SSL connections to older devices
[\#1654](#1654) (@kad)
- waterleaksensor: use parent's Time for alert timestamp
[\#1614](#1614)
(@rytilahti)
- Add hold state to thermostatstate
[\#1609](#1609)
(@rytilahti)
- Fix thermostat idle reporting on low battery
[\#1598](#1598)
(@rytilahti)
- Add shutdown \(summer mode\) to thermostatstate
[\#1588](#1588)
(@rytilahti)
- Fix iotstrip child device time handling
[\#1584](#1584)
(@ZeliardM)

**Added support for devices:**

- Add C200 device fixture
[\#1760](#1760) (@juherr)
- Add P125M fixture for firmware 1.4.4
[\#1746](#1746)
(@HarryPehkonen)
- Add fixtures for KH100, KE100 and KE110 and simulate TRV states
[\#1726](#1726) (@Krotu)
- Add L530EA\(EU\) device fixture
[\#1694](#1694)
(@ZeliardM)
- Add C101 test fixture
[\#1673](#1673) (@ijaron)
- Add LB130\(US\) device fixture
[\#1669](#1669)
(@ZeliardM)
- Add KL110B\(UN\) device fixture
[\#1657](#1657)
(@ZeliardM)
- Add TS15\(US\) device fixture
[\#1649](#1649)
(@ZeliardM)
- Add Tapo C460 support
[\#1645](#1645)
(@markvanpraet)
- Add P105\(US\) device fixture
[\#1644](#1644)
(@ZeliardM)
- Add L430C\(EU\) device fixture
[\#1643](#1643)
(@ZeliardM)
- Add L430P\(EU\) device fixture
[\#1607](#1607)
(@LostLuma)
- Add S500\(US\)\_1.0\_1.2.0 fixture
[\#1569](#1569)
(@ZeliardM)
- Add device fixture for P316M\(US\)
[\#1568](#1568)
(@TheLinuxGuy)
- Add L535E\(EU\) 3.0 1.1.8 fixture
[\#1545](#1545)
(@fantandrea)
- Adding KL400L10\(US\)\_1.0\_1.0.10 fixture
[\#1539](#1539) (@mjbohr)
- Add TP10\(IT\) 1.0 1.2.5 fixture
[\#1538](#1538)
(@emanueleg)
- Add LB100\(US\)\_1.0\_1.8.11 fixture file
[\#1515](#1515)
(@ZeliardM)
- Add KS225\(US\)\_1.0\_1.1.1 and L930-5\(EU\)\_1.0\_1.2.5
[\#1509](#1509)
(@ZeliardM)

**Documentation updates:**

- How to hash credentials to make use of --credentials-hash flag?
[\#1517](#1517)
- docs: modernize docstrings across the repository
[\#1682](#1682)
(@ZeliardM)
- Add a note to emeter guide being kasa-only
[\#1512](#1512)
(@rytilahti)

**Project maintenance:**

- Fix PyPI publishing for packages with metadata 2.5
[\#1779](#1779)
(@rytilahti)
- tests: add type annotations to top-level test files
[\#1688](#1688)
(@ZeliardM)
- tests: add type annotations to CLI, protocol, and smartcam tests
[\#1687](#1687)
(@ZeliardM)
- tests: add type annotations to Smart tests
[\#1686](#1686)
(@ZeliardM)
- tests: add type annotations to IoT tests
[\#1685](#1685)
(@ZeliardM)
- tests: add type annotations to transport tests
[\#1684](#1684)
(@ZeliardM)
- tests: centralize transport and session cleanup in conftest
[\#1683](#1683)
(@ZeliardM)
- ci: pin all GitHub Actions to SHA hashes and update versions
[\#1681](#1681)
(@ZeliardM)
- tests: fix typos, child device subtype, CLI patch path, and
deprecation test logic
[\#1677](#1677)
(@ZeliardM)
- Update GitHub Workflows and Actions
[\#1622](#1622)
(@ZeliardM)
- Use log-level debug for smartdevice query error reporting
[\#1587](#1587)
(@rytilahti)
- Use Device instead of SmartDevice where feasible
[\#1585](#1585)
(@ZeliardM)

**Closed issues:**

- Python 3.14 Support
[\#1597](#1597)
- HS300 Child State - Time Module Error
[\#1445](#1445)
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

maintenance Project improvements and maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL