Skip to content

Fix is_closed state for DiscretePositionableGarageDoor in Overkiz#170981

Merged
zweckj merged 4 commits into
home-assistant:devfrom
iMicknl:fix-overkiz-discrete-positionable-garage-door
May 18, 2026
Merged

Fix is_closed state for DiscretePositionableGarageDoor in Overkiz#170981
zweckj merged 4 commits into
home-assistant:devfrom
iMicknl:fix-overkiz-discrete-positionable-garage-door

Conversation

@iMicknl
Copy link
Copy Markdown
Member

@iMicknl iMicknl commented May 17, 2026

Proposed change

Fix cover state for Somfy Rollixo IO (DiscretePositionableGarageDoor widget) which reports core:OpenClosedUnknownState instead of core:OpenClosedState and does not support position control.

After the cover platform migration to entity descriptions (#141330), this device falls through to the UIClass.GARAGE_DOOR default which looks for core:OpenClosedState and core:ClosureState — neither of which exist on this device. This causes the cover to always show as "unknown" state.

The fix adds a widget-specific override for UIWidget.DISCRETE_POSITIONABLE_GARAGE_DOOR that uses the correct CORE_OPEN_CLOSED_UNKNOWN state and omits position control (which this device doesn't support).

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Deprecation (breaking change to happen in the future)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

Checklist

  • I understand the code I am submitting and can explain how it works.
  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • I have followed the perfect PR recommendations
  • The code has been formatted using Ruff (ruff format homeassistant tests)
  • Tests have been added to verify that the new code works.
  • Any generated code has been carefully reviewed for correctness and compliance with project standards.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies a diff between library versions and ideally a link to the changelog/release notes is added to the PR description.

To help with the load of incoming pull requests:

iMicknl added 3 commits May 17, 2026 12:54
The DiscretePositionableGarageDoor widget (e.g. Somfy Rollixo IO) reports
core:OpenClosedUnknownState instead of core:OpenClosedState and does not
support position control. Without a widget-specific override, the device
falls through to the UIClass.GARAGE_DOOR default which looks for wrong
states, causing the cover to always report unknown state.

Fixes home-assistant#170966
Restore original unicode characters that were incorrectly converted to
escape sequences, and remove paramsSig fields that are not present in
the cloud API format.
The diagnostics were from a local API setup, so the fixture belongs in
local_somfy_tahoma_v2_europe.json with the proper local format (includes
paramsSig, subsystemId, synced fields; excludes cloud-only fields).
Copilot AI review requested due to automatic review settings May 17, 2026 13:19
@iMicknl iMicknl added this to the 2026.5.3 milestone May 17, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes the Overkiz cover entity mapping for Somfy Rollixo IO devices using the DiscretePositionableGarageDoor widget so the entity reports a correct is_closed state (and does not expose unsupported position control) after the cover platform migration to entity descriptions.

Changes:

  • Add a widget-specific OverkizCoverDescription for UIWidget.DISCRETE_POSITIONABLE_GARAGE_DOOR using core:OpenClosedUnknownState.
  • Extend the Overkiz cover service-action tests to include the discrete garage door device.
  • Update the local TaHoma fixture and snapshot to include and validate the new device behavior.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
homeassistant/components/overkiz/cover.py Adds a widget-specific override so is_closed is derived from CORE_OPEN_CLOSED_UNKNOWN and position support is not enabled.
tests/components/overkiz/test_cover.py Adds the discrete garage door fixture device to service-action test coverage (open/close/stop).
tests/components/overkiz/snapshots/test_cover.ambr Updates snapshots to include the new entity registry entry/state for the added device.
tests/components/overkiz/fixtures/setup/local_somfy_tahoma_v2_europe.json Adds a representative DiscretePositionableGarageDoor device payload to reproduce/validate the issue.

@zweckj zweckj merged commit 9ce3e00 into home-assistant:dev May 18, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

is_closed state is unknown for DiscretePositionableGarageDoor after 2026.5 in Overkiz

3 participants