Skip to content

feat!: remove non-functional Zigbee room enrichment#757

Merged
CFenner merged 2 commits intoopenviess:masterfrom
lackas:remove-zigbee-enrichment
May 8, 2026
Merged

feat!: remove non-functional Zigbee room enrichment#757
CFenner merged 2 commits intoopenviess:masterfrom
lackas:remove-zigbee-enrichment

Conversation

@lackas
Copy link
Copy Markdown
Contributor

@lackas lackas commented May 7, 2026

Summary

The RoomControl-driven Zigbee enrichment introduced in #743 does not work in practice: the rooms.{id}.actors mapping that drives buildActorRoomMap() is not returned by the API for end users, so the enrichment is silently no-op and the lib has no reliable path to associate physical Zigbee devices with rooms.

This PR removes the enrichment plumbing and reverts RoomSensor to direct sensor reads (device.sensors.temperature, device.sensors.humidity). RoomControl itself stays — it still works for direct per-room access (getRoomTemperature(room_id), getRoomHumidity(room_id), etc.).

Changes

  • Remove PyViCare.__enrichZigbeeDevices() and its call in __loadInstallations
  • Remove RoomControl.buildActorRoomMap()
  • Remove PyViCareDeviceConfig.setRoomControlEnrichment(), _room_control/_room_id fields, and the enrichment branch in asRoomSensor
  • Simplify RoomSensor to direct device.sensors.* access (drop hybrid getters that depended on enrichment)
  • Remove the corresponding tests in test_RoomControl.py

Net: -253 / +3 LoC, full suite 725 passed.

Breaking change

RoomSensor no longer exposes the hybrid getters that required RoomControl context: getRoomName, getRoomType, getCondensationRisk, getOperatingStateLevel, getOperatingStateDemand, getNormalHeatingTemperature, getReducedHeatingTemperature, getComfortHeatingTemperature, setNormal/Reduced/ComfortHeatingTemperature, getManualTillNextScheduleActive, activate/deactivateManualTillNextSchedule, getSchedule. Use the corresponding RoomControl methods with a room_id directly.

Follow-up

A future PR could expose RoomControl data via a different integration pattern (virtual room entities or similar). That work is independent of this revert.

The RoomControl-driven Zigbee enrichment introduced in openviess#743 does not
work in practice: the rooms.{id}.actors mapping that drives
buildActorRoomMap() is not returned by the API for end users, so the
enrichment is silently no-op and the lib has no reliable path to
associate physical Zigbee devices with rooms.

Removes the enrichment plumbing and reverts RoomSensor to direct
sensor reads (device.sensors.temperature, device.sensors.humidity).
RoomControl itself stays for direct per-room access.

BREAKING CHANGE: RoomSensor no longer exposes hybrid getters that
required RoomControl context (getRoomName, getRoomType,
getCondensationRisk, getOperatingState*, getNormal/Reduced/Comfort
HeatingTemperature, getManualTillNextSchedule*, getSchedule).
Use the corresponding RoomControl methods with a room_id directly.
@CFenner CFenner merged commit 72103af into openviess:master May 8, 2026
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants