Skip to content

fix: treat o3 docks as dryable when the device supports drying - #1065

Open
ryanmac8 wants to merge 1 commit into
Python-roborock:mainfrom
ryanmac8:fix/o3-dock-optional-dryer-module
Open

ryanmac8 wants to merge 1 commit into
Python-roborock:mainfrom
ryanmac8:fix/o3-dock-optional-dryer-module

Conversation

@ryanmac8

Copy link
Copy Markdown

Problem

RoborockDockFeatures.is_dryable is derived from the dock type alone, so docks in _COLLECT_WASH_DOCK_TYPES are never considered dryable. o3_dock (the Empty Wash Fill dock used by the S7 MaxV Ultra) is one of them, but it supports the separately sold dryer module (HADM02RR). A device with that module installed advertises is_supported_drying: true.

Today that means MopDryerTrait is never created for these devices, so consumers such as Home Assistant never see the dock drying controls, and the "Mop drying remaining time" sensor stays unknown.

Fixes #1037.

Change

  • RoborockDockFeatures gains an optional supports_drying field, populated from the device's is_supported_drying feature during trait discovery.
  • is_dryable returns true for dry-capable dock families as before, or when the device advertises drying support.

Dock families that dry on their own are unaffected, because is_collect_wash_dry is still checked first, and devices that don't advertise the feature keep the previous behaviour since the field defaults to None.

Verification

Unit tests added for the capability matrix (tests/test_supported_features.py) and for the trait gate (tests/devices/traits/v1/test_mop_dryer.py).

Verified against a real S7 MaxV (roborock.vacuum.a27, firmware 02.59.36) with an o3_dock and the HADM02RR module installed.

Before:

is_supported_drying: True
dock_features: RoborockDockFeatures(dock_type=<RoborockDockTypeCode.o3_dock: 3>, has_am=None)
is_dryable: False
mop_dryer trait present: False

After:

is_supported_drying: True
dock_features: RoborockDockFeatures(dock_type=<RoborockDockTypeCode.o3_dock: 3>, has_am=None, supports_drying=True)
is_dryable: True
mop_dryer trait present: True
auto-drying enabled: True | dry_time: 10800

uv run pytest (2365 passed, 53 xfailed), ruff clean, mypy unchanged from main (the 19 reported errors are pre-existing and none are in the touched files).

This branch has not been deployed

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

Labels

bug Something isn't working Small PR Small pull request (<200 lines) V1 V1 platform

Projects

None yet

Development

Successfully merging this pull request may close these issues.

S7 MaxV Ultra: Dock Dryer Module (HADM02RR) on Empty Wash Fill Dock (o3_dock) not detected - no mop dryer trait

2 participants