core: ZHA Light platform group fails to control all lights in group

Home Assistant release with the issue:

0.88.1

Last working Home Assistant release (if known):

0.87.1 Operating environment (Hass.io/Docker/Windows/etc.):

Hass.io on Raspberry Pi 3 with a conbee USB zigbee coordinator Component/platform:

ZHA

Description of problem: I’ve had a few issues and several errors since moving from 0.87.1 to 0.88 (and now 0.88.1). I think that I have found the source of some of my problems. I have a light configured as a group (see YAML below). Physically this is 5 Tradfri bulbs all on a single switch - they are grouped (light: -platform: group) to behave as a single light, in this case light.stairs_light. All the light seem to work individually, but only one will work when controlled by the light.stairs_light group. However turning on any one of the lights will effect the state of the group. e.g.

  • Turn on the group, only light 1 turns on (could be any light after each reboot, currently its light 5). Turn off the group only light 1 turns off.
  • Turn on light 3 - group shows as on. Turn off light 3 group shows as off.
  • Turn on light 3, group shows as on. Turn off the group - nothing happens.

In version 0.87.1 (which I have tried restoring to confirm), all lights are controlled by the light.stairs_light group. I think this is something to do with the light being initially unavailable in version 0.88.1, when that group is created. Only the first light is correctly added, perhaps?

I can get around this by not using this configuration, but it seems like there is a bug somewhere.

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):


light:
  - platform: group
    name: Stairs Light
    entities:
      - light.stairs_1
      - light.stairs_2 
      - light.stairs_3
      - light.stairs_4
      - light.stairs_5

Traceback (if applicable):

Various errors - not sure which are relevant or helpful… These are from around the time I was switching lights on and off.

2019-02-26 14:18:13 WARNING (MainThread) [zigpy_deconz.zigbee.application] Failed to receive transmit confirm for request id: 117
2019-02-26 14:18:13 WARNING (MainThread) [zigpy_deconz.zigbee.application] Failed to receive transmit confirm for request id: 118
2019-02-26 14:18:13 WARNING (MainThread) [zigpy_deconz.zigbee.application] Failed to receive transmit confirm for request id: 119
2019-02-26 14:18:14 INFO (MainThread) [homeassistant.components.http.view] Serving /api/history/period/2019-02-25T14:18:13.549Z to 192.168.1.70 (auth: True)
2019-02-26 14:18:14 INFO (SyncWorker_17) [homeassistant.components.device_tracker.nmap_tracker] nmap scan successful
2019-02-26 14:18:22 WARNING (MainThread) [zigpy_deconz.zigbee.application] Failed to receive transmit confirm for request id: 120
2019-02-26 14:18:22 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 289, in _handle_service_platform_call
    await getattr(entity, func)(**data)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/zha/light.py", line 206, in async_turn_off
    success = await self._on_off_channel.off()
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/zha/core/channels/__init__.py", line 48, in wrapper
    result = await command(*args, **kwds)
  File "/usr/local/lib/python3.7/site-packages/zigpy/device.py", line 89, in request
    expect_reply=expect_reply,
  File "/usr/local/lib/python3.7/site-packages/zigpy_deconz/zigbee/application.py", line 97, in request
    r = await asyncio.wait_for(send_fut, SEND_CONFIRM_TIMEOUT)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 423, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2019-02-26 14:18:23 INFO (MainThread) [homeassistant.components.http.view] Serving /api/history/period/2019-02-26T14:18:05.113Z to 192.168.1.70 (auth: True)
2019-02-26 14:18:30 INFO (SyncWorker_18) [homeassistant.components.device_tracker.nmap_tracker] Scanning...
2019-02-26 14:18:33 WARNING (MainThread) [zigpy_deconz.zigbee.application] Failed to receive transmit confirm for request id: 121
2019-02-26 14:18:33 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 289, in _handle_service_platform_call
    await getattr(entity, func)(**data)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/zha/light.py", line 206, in async_turn_off
    success = await self._on_off_channel.off()
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/zha/core/channels/__init__.py", line 48, in wrapper
    result = await command(*args, **kwds)
  File "/usr/local/lib/python3.7/site-packages/zigpy/device.py", line 89, in request
    expect_reply=expect_reply,
  File "/usr/local/lib/python3.7/site-packages/zigpy_deconz/zigbee/application.py", line 97, in request
    r = await asyncio.wait_for(send_fut, SEND_CONFIRM_TIMEOUT)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 423, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError

Additional information:

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 36 (18 by maintainers)

Most upvoted comments

@styxyDog I’m working on a better solution. Hopefully will have something for you to try by the end of the weekend.

The error one is a question for Zigpy deconz. The other happens from time to time and is a warning… safe to ignore.

Nope, thx man

Yeah I’ll keep looking at this too. Something is definitely up here.