Code Monkey home page Code Monkey logo

ha-lifx-beta's Introduction

Who am I?

Setting the more existential question aside, I am Avi Miller.

During the day, I do open source things for Oracle Cloud Infrastructure.

At night and on weekends, my love for technology extends to annoying my husband with smart home upgrades as well as more useful stuff like volunteering for community-based organizations.

What's here

I am not actually a real developer, but I'm very good at pretending to be one on the internet.

Mostly I dabble. Every now and then I noodle on things too. The results of my dabbling and noodling can be found in the various repos herein contained.

I'm particularly proud of the following things I've dabbled with and noodled on:

I'm also rather proud of my contributions to Photons, a Python 3.6+ framework for interacting with LIFX products. Photons is used by the docker-lifx-daydusk container.

What's not here

Stuff I maintain professionally for Oracle including the following repos:

I contribute to the following repos:

I manage the official Oracle Linux images on Docker Hub, the Oracle Container Registry and the GitHub Container Registry which are built from the rootfs tarballs in this repo:

Finally, I am also one of the GitHub administrators for Oracle. If you have any questions about Oracle's open source projects or contributions, please email the team at [email protected].

ha-lifx-beta's People

Contributors

djelibeybi avatar lukyjay avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ha-lifx-beta's Issues

Bulb going unavailable

I'm seeing

DEBUG (MainThread) [custom_components.lifx.light] Disconnected from Entrance Light 02 (MAC)

from a couple downlights (LIFX DL Colour 700lm) - firmware 2.80
Wifi strength : 3/5

They are on a dedicated vlan, using the specific broadcast configuration to loop them in. I dont have them connected to the LIFX cloud, however I can connect to that VLAN with my phone and the light responds instantly.

If I reload the integration, the light is picked up immediately for another few hours.

There are maybe 3-4 lights that consistently display this behaviour. According to my UNIFI integration, the light stays online.

There are 21 downlights in total, all are hardwired effectively and can't be turned off (except at the breaker). There are multiple AP's with no connectivity issues.

It does not appear to be reconnecting until the integration is reloaded - certainly it goes hours.

Running latest 2022.07.01

A periodic service that lets me schedule a rescan / reconnect - I can see when they go unavailable, and afaict they are definitely not unavailable - I'm just gonna automate that, I'm not too far off just automating an integration reload at the moment.

HACS compatible

This integration doesn't appear in HACS "Add repository" search accessed by using the "+Explore & Download Repositories" button.

HA version: 2022.5.5
HACS version: 1.25.0

Latest beta throws time out warnings

With the latest beta from today it's throwing hundreds of these warnings per hour. The Mac seems to be all zeroes so maybe it's indicating an issue with either the integration or at least with the log message.

Logger: custom_components.lifx
Source: custom_components/lifx/coordinator.py:184
Integration: LIFX ([documentation](https://github.com/Djelibeybi/ha-lifx-beta))
First occurred: 22:59:01 (482 occurrences)
Last logged: 23:41:36

Time out updating 192.168.8.45 (00:00:00:00:00:00). Reconnecting.
Time out updating 192.168.8.42 (00:00:00:00:00:00). Reconnecting.
Time out updating 192.168.8.43 (00:00:00:00:00:00). Reconnecting.
Time out updating 192.168.8.39 (00:00:00:00:00:00). Reconnecting.
Time out updating 192.168.8.41 (00:00:00:00:00:00). Reconnecting.

Feedback on 2022.11.0-dev

Hey,

Some feedback on 2022.11.0-dev after 24 hours or so. Everything is looking good, lights seem at least as responsive as before and nothing has been marked unavailable.

I have some log messages, but this is quite a lot less than I would normally expect to see.

Logger: custom_components.lifx
Source: custom_components/lifx/util.py:199
Integration: LIFX
First occurred: November 23, 2022 at 11:52:40 PM (6 occurrences)
Last logged: 7:14:27 AM

No response from LIFX bulb Dining Table Pendant 1 after 8.2568 secs
No response from LIFX bulb Dining Table Pendant 1 after 8.2744 secs
No response from LIFX bulb Dining Table Pendant 1 after 8.2552 secs
No response from LIFX bulb Living Room 14 after 8.2561 secs
No response from LIFX bulb Dining Table Pendant 1 after 8.2561 secs

None of these resulted in the bulb going unavailable.

Cheers,

Lifx devices not showing up since recent discover refactor

Since the recent upgrade, lifx devices do not show up. My system is on a rpi4. It has ethernet and wifi networks, each on separate subnets. Lifx devices are discoverable and work fine in iOS app. Lifx is only on the wifi subnet.

I installed the latest beta (2022.06.06) and have setup debug logs per instructions, but I don't see any clues as to why nothing is being discovered. This is what I put in my configutaion.yaml:

logger:
  default: info
  logs:
    custom_components.lifx: debug

Nothing stands out in my logs regarding lifx. You mentioned in a previous comment that I need to go throuigh the UI to enable it. I deleted and re-added the integration and it still doesn't work (it's actually worse now, as my lifx devices are now missing completely).

Logs:
home-assistant.log

Latest beta introduce new python errors

With the latest beta as of today, the following errors are showing a lot in the logs.

This error originated from a custom integration.

Logger: homeassistant
Source: custom_components/lifx/light.py:345
Integration: LIFX (documentation)
First occurred: 17 January 2023 at 21:49:02 (669 occurrences)
Last logged: 01:09:16

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 168, in _handle_refresh_interval
await self._async_refresh(log_failures=True, scheduled=True)
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 316, in _async_refresh
self.async_update_listeners()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 121, in async_update_listeners
update_callback()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 381, in _handle_coordinator_update
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 556, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 599, in _async_write_ha_state
attr.update(self.state_attributes or {})
File "/usr/src/homeassistant/homeassistant/components/light/init.py", line 986, in state_attributes
color_mode = self._light_internal_color_mode
File "/usr/src/homeassistant/homeassistant/components/light/init.py", line 812, in _light_internal_color_mode
if (color_mode := self.color_mode) is None:
File "/config/custom_components/lifx/light.py", line 345, in color_mode
has_sat = self.bulb.color[HSBK_SATURATION]
TypeError: 'NoneType' object is not subscriptable

And

Log Details (ERROR)
Logger: homeassistant.components.light
Source: helpers/entity_platform.py:536
Integration: Light (documentation, issues)
First occurred: 17 January 2023 at 21:48:33 (14 occurrences)
Last logged: 17 January 2023 at 21:48:33

Platform lifx does not generate unique IDs. ID 00:00:00:00:00:00 already exists - ignoring light.lifx_00_00_00_00_00_00

And also this one

Log Details (ERROR)
Logger: homeassistant.components.sensor
Source: custom_components/lifx/coordinator.py:150
Integration: Sensor (documentation, issues)
First occurred: 17 January 2023 at 21:48:33 (15 occurrences)
Last logged: 17 January 2023 at 21:48:33

Error while setting up lifx platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 289, in _async_setup_platform
await asyncio.shield(task)
File "/config/custom_components/lifx/sensor.py", line 47, in async_setup_entry
async_add_entities([LIFXRssiSensor(coordinator, RSSI_SENSOR)])
File "/config/custom_components/lifx/sensor.py", line 104, in init
self._attr_native_unit_of_measurement = coordinator.rssi_uom
File "/config/custom_components/lifx/coordinator.py", line 150, in rssi_uom
if AwesomeVersion(self.device.host_firmware_version) <= RSSI_DBM_FW:
File "/usr/local/lib/python3.10/site-packages/awesomeversion/awesomeversion.py", line 202, in le
return self.eq(compareto) or self.lt(compareto)
File "/usr/local/lib/python3.10/site-packages/awesomeversion/awesomeversion.py", line 176, in lt
raise AwesomeVersionCompareException(
awesomeversion.exceptions.AwesomeVersionCompareException: Can't compare and <SimpleVer 2.77>

Remove Integration

Is there any-way to remove this integration without removing the whole Lifx integration and losing device names, areas etc. that are all setup?

LIFX not being discovered

Heyo

I recently decided to updated HA (container) to the latest, and noticed that LIFX was not being discovered in the Integration (after finding it was undiscoverable).

I went through a bunch of troubleshooting and eventually ended up putting manual config in the configuration.yaml

lifx:
light:
- server: IP_ADDRESS
port: 56700
broadcast: IP_ADDRESS

Then it started working (I can control and it discovered). Is there a current issue with the integration where it can't discover my lights?

2.1 Update doesn't allow manual specification of Lifx via config.yaml

Since update, LIFX config doesn't allow "broadcast" in configuration.yaml for LIFX integration.

Ie. I've still had a LIFX includes file that has all my LIFX static IPs listed out.

lifx:
  light:
    - broadcast: 192.168.3.156 #LIFX-Balcony-1
    - .....
    - .....

Although I originally did this as dynamic discovery was unreliable and I've got 92 lights lights in total. I've commented my LIFX include out for now and will give the dynamic discovery more of a test, initally just tested once for startup times then reverted back.

Would be good to support static definition per above though as an option, especially for folks already using older lifx integration if they migrate.

LIFX Lights go unavailable during light up dim automation or otherwise sporadically after commands are issued to them.

2023-01-08 00:01:57.504 ERROR (MainThread) [custom_components.lifx] Error fetching Stairs 1 (10.0.53.3) data: Failed to update Stairs 1: No response from Stairs 1 (10.0.53.3) [d0:73:d5:2e:46:47]

What version of Home Assistant Core has the issue?
Home Assistant 2023.1.1
Supervisor 2022.12.1
Operating System 9.4
Frontend 20230104.0 - latest

What was the last working version of Home Assistant Core?
Don't remember I update regularly as new versions come out. However I didn't use to have this problem a while back.

What type of installation are you running?
Version | core-2023.1.1
Installation Type | Home Assistant OS

Integration causing the issue
LIFX Official
https://www.home-assistant.io/integrations/lifx/
LIFX Beta as well.
https://github.com/Djelibeybi/ha-lifx-beta

config_entry-lifx-258a5b54153c3faaa013d311f9652537.json.txt

Log File relevant message:
2023-01-08 00:01:57.504 ERROR (MainThread) [custom_components.lifx] Error fetching Stairs 1 (10.0.53.3) data: Failed to update Stairs 1: No response from Stairs 1 (10.0.53.3) [d0:73:d5:2e:46:47]

Object has no attribute error seen in logs

In the latest beta I saw this error in the logs.

I had noticed some bulbs never go unavailable even though they had been switched off all night so was checking the logs for clues.

I'm using these settings

Discovery Interval: 200
Message Reply Timeout: 2
Retry Count: 3
Grace Period: 180

Seems like an exception was thrown while handling of another. Some key that didn't exist.

Log Details (ERROR)
This error originated from a custom integration.
Logger: homeassistant
Source: custom_components/lifx/light.py:476
Integration: LIFX (documentation, issues)
First occurred: 02:45:18 (9 occurrences)
Last logged: 03:03:18

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/asyncio/locks.py", line 226, in wait
    await fut
asyncio.exceptions.CancelledError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/config/custom_components/lifx/aiolifx/aiolifx.py", line 318, in try_sending
    myresult = await aio.wait_for(event.wait(), timeout_secs)
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/lifx/aiolifx/aiolifx.py", line 328, in try_sending
    self.unregister()
  File "/config/custom_components/lifx/aiolifx/aiolifx.py", line 223, in unregister
    self.parent.unregister(self)
  File "/config/custom_components/lifx/aiolifx/aiolifx.py", line 1424, in unregister
    self.parent.unregister(alight)
  File "/config/custom_components/lifx/light.py", line 476, in unregister
    entity.elapsed,
AttributeError: 'LIFXColor' object has no attribute 'elapsed'

Startup Delay / Error

After restart sometimes there's a delay until light entites are available even though it looks like the integration has discovered them successfully.

Logger: homeassistant
Source: custom_components/lifx/light.py:774
Integration: LIFX (documentation, issues)
First occurred: 19:12:15 (3 occurrences)
Last logged: 19:12:15

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 382, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 613, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 748, in add_to_platform_finish
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 505, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 540, in _async_write_ha_state
    attr.update(self.state_attributes or {})
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 882, in state_attributes
    color_mode = self._light_internal_color_mode
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 723, in _light_internal_color_mode
    if COLOR_MODE_HS in supported and self.hs_color is not None:
  File "/config/custom_components/lifx/light.py", line 774, in hs_color
    hue, sat, _
[hass_lifx_beta_error_logs.log](https://github.com/Djelibeybi/ha-lifx-beta/files/7861134/hass_lifx_beta_error_logs.log)
, _ = self.bulb.color
TypeError: cannot unpack non-iterable NoneType object

Full log attached
hass_lifx_beta_error_logs.log

LIFX Switch Buttons not available on some switches

I'm on 2023.4.4. I have about 8 LIFX Switches connected to HA via Homekit Controller. My switches control a mix of Lifx bulbs and normal relays.

I have automations setup to respond to button presses, e.g. "single press" button1 and toggle my lights or lightgroups. For most, this works great, but I have two different switches that aren't exposing their button events, only the terminal events.

This is what a working one looks like:
image

This is one that isn't working:
image

I've tried removing the switches and re-pairing them to Homekit Controller, but the events aren't there.

This is how the working switch is configured in the LIFX app:

Wiring Setup:
  Terminal 1:
    Is this terminal wired? Yes
    What is it wired to? LIFX Light
  Terminal 2:
    Is this terminal wired? Yes
    What is it wired to? LIFX Light  
Buttons:
  All empty

This is how the non-working switch is configured:

Wiring Setup:
  Terminal 1:
    Is this terminal wired? Yes
    What is it wired to? LIFX Light
  Terminal 2:
    Is this terminal wired? No
  Terminal 3:
    Is this terminal wired? No
  Terminal 4:
    Is this terminal wired? No
Buttons:
  All empty

Any ideas or info I can provide?

Integration broken w/VLAN in 5.5+ (including recent beta)

Any version of HA from 5.5 onwards (including the new 6.1) breaks the LIFX integration for me. Existing bulbs show offline and do not come back even if the integration is reloaded. If I delete and re-add the integration, it doesn't discover any bulbs at all. I've tried with the built in integration and this beta via HACs, same behavior.

I'm wondering if this has to do with my VLAN. My bulbs site on a different VLAN on my network (192.168.40.x my "regular" subnet is 192.168.1.x). HA is configured for both networks, can ping items on both from the console, including the bulbs themselves (which I have configured statically on that VLAN). Prior to 5.5 it discovered them just fine. In fact my current "solution" is rolling back to the last backup I have of 4.7, at which point they start working again.

Did something change and perhaps HA no longer looks beyond it's default interface for bulb discovery? If so that will break more setups than mine, it's fairly common to put "IOT" stuff on a separate VLAN.

Appreciate the work on the beta and any insight you can offer!

One bulb not staying available

Currently on 2022.06.06 of this integration.
I have 3 LIFX bulbs. Two color bulbs (LIFX A19) and one white bulb (White 800). With the stock Home Assistant integration, I originally had issues with all bulbs as of the last version or so of Home Assistant. With the current beta version of this integration, I only have issues with the white bulb. No matter what I do, it goes unavailable after a bit of time after a power cycle.

I see these messages for each of my bulbs, but the White one I see it multiple times (some information scrubbed):

2022-06-11 07:43:11 DEBUG (MainThread) [custom_components.lifx.light] First discovery response received from 192.168.xx.xx (mac)

Later I see this for the White bulb:
2022-06-11 07:43:12 DEBUG (MainThread) [custom_components.lifx.light] Failed to discover product information for 192.168.xx.xx (mac)

It repeates over and over in my logs. Bulb and Home Assistant are on the same subnet, so it isnt a discovery or firewall issue. Everything was working until the last version of Home Assistant I believe.

Power cycling brings it back, then it drops off again some time later.

Ill do some tests later and post more logs (before, during, after power cycle).

Stability Issues detected in logs on latest version

Upgraded the Lifx beta to 2022.06.05 this morning and now getting the following errors, there were no issues reported in the logs on the previous version.

Detected blocking call to sleep inside the event loop. This is causing stability issues. Please report issue for rest doing blocking calls at homeassistant/components/rest/sensor.py, line 172: json_dict = json.loads(value)
Detected blocking call to sleep inside the event loop. This is causing stability issues. Please report issue to the custom component author for lifx doing blocking calls at custom_components/lifx/light.py, line 562: self.event = asyncio.Event()
Detected blocking call to sleep inside the event loop. This is causing stability issues. Please report issue to the custom component author for lifx doing blocking calls at custom_components/lifx/light.py, line 574: method(callb=self.callback)
Detected blocking call to sleep inside the event loop. This is causing stability issues. Please report issue for rest doing blocking calls at homeassistant/components/rest/sensor.py, line 160: value = json.dumps(xmltodict.parse(value))

image

Lights showing incorrect state when power cycled & extraneous light device/entity

Thank you for the beta fix. I installed it yesterday and it seems to have fixed the issue with the lights becoming unavailable frequently - however I believe it introduced a couple of new issues.

A little background: I have several bulbs connected to either dumb switches, or smart switches that just power cycle. In either case, I have half a dozen bulbs that are not always powered on. Not ideal, but was never much of an issue before - they would become controllable a minute or so after powering on.

The first issue. When I installed the beta fix, it created a new device called 'Restart', with a light entity that appears to just be named with a bogus MAC address. It then linked this device to all existing bulbs that were offline at the time. So I have this one strange device linked to 6 bulbs:

image

You'll notice the Integration says LIFX 6 times - one for each bulb it's linked to. And here is the device info.

image
image

That's probably minor, and I can clean it up manually if needed, but it's something to be aware of.

Second issue This one is a bigger issue. I've noticed that now the availability of the lights does not always reflect the actual state. The most obvious is lights showing online that have since been power cycled and are off. You can see that here:
image

The switches controlling the Front Porch and Balcony lights are off - the bulbs have no power. However they still show online, you can attempt to set colors, brightness, etc. Of course doing so is unsuccessful, and results in loads of errors in the log

2022-12-20 10:18:22.202 ERROR (MainThread) [homeassistant.components.light] Error adding entities for domain light with platform lifx
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 428, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 692, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 789, in add_to_platform_finish
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 545, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 585, in _async_write_ha_state
    attr.update(self.state_attributes or {})
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 986, in state_attributes
    color_mode = self._light_internal_color_mode
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 812, in _light_internal_color_mode
    if (color_mode := self.color_mode) is None:
  File "/config/custom_components/lifx/light.py", line 357, in color_mode
    has_sat = self.bulb.color[HSBK_SATURATION]
TypeError: 'NoneType' object is not subscriptable
2022-12-20 10:18:22.215 ERROR (MainThread) [homeassistant.components.light] Error while setting up lifx platform for light
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 289, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 428, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 692, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 789, in add_to_platform_finish
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 545, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 585, in _async_write_ha_state
    attr.update(self.state_attributes or {})
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 986, in state_attributes
    color_mode = self._light_internal_color_mode
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 812, in _light_internal_color_mode
    if (color_mode := self.color_mode) is None:
  File "/config/custom_components/lifx/light.py", line 357, in color_mode
    has_sat = self.bulb.color[HSBK_SATURATION]
TypeError: 'NoneType' object is not subscriptable
2022-12-20 10:18:44.468 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 168, in _handle_refresh_interval
    await self._async_refresh(log_failures=True, scheduled=True)
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 316, in _async_refresh
    self.async_update_listeners()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 121, in async_update_listeners
    update_callback()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 381, in _handle_coordinator_update
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 545, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 585, in _async_write_ha_state
    attr.update(self.state_attributes or {})
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 986, in state_attributes
    color_mode = self._light_internal_color_mode
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 812, in _light_internal_color_mode
    if (color_mode := self.color_mode) is None:
  File "/config/custom_components/lifx/light.py", line 357, in color_mode
    has_sat = self.bulb.color[HSBK_SATURATION]
TypeError: 'NoneType' object is not subscriptable
2022-12-20 10:19:06.467 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 168, in _handle_refresh_interval
    await self._async_refresh(log_failures=True, scheduled=True)
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 316, in _async_refresh
    self.async_update_listeners()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 121, in async_update_listeners
    update_callback()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 381, in _handle_coordinator_update
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 545, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 585, in _async_write_ha_state
    attr.update(self.state_attributes or {})
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 986, in state_attributes
    color_mode = self._light_internal_color_mode
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 812, in _light_internal_color_mode
    if (color_mode := self.color_mode) is None:
  File "/config/custom_components/lifx/light.py", line 357, in color_mode
    has_sat = self.bulb.color[HSBK_SATURATION]

Similarly, it seems that some lights simply never showed online, even after power was restored. In both cases reloading the integration for those bulbs updated it to the correct state, however it does not update properly again with the next power cycle - so you're back at square one.

If you want me to open separate issues for these please let me know. I figured the root cause of both was likely the powering of the bulbs. Please let me know if you need any more info

Lifx Bulbs going unavailable.

Since moving to HA 2022.5 stability dropped, but I've had less problems with newer versions of the ha-lifx-beta - I'm down to 1-2 bulbs per day going unavailable, so I think the majority of the problems are fixed.

Version of ha-lifx-beta: 2022.06.02: bump aiolifx version

image
image
image
image
image

I looked at the logs this is the only thing for Lifx today

image

Is there a way to pull more detailed logs for this?

Z Strips Becoming Unrespnsive

Using the beta here to try and mitigate connection issues. I have two Z Strips that are still losing connection with Home Assistant. They are always available in the LIFX App.

Prior to the beta I would restart my router and they’d reappear. After installing the beta they lose connection less frequently but when they do I need to delete the LIFX integration, restart my router, then restart Home Assistant to get them to appear again. Any thoughts on how to fix this? The two Z Strips are the only LIFX devices I have.

Lights unavailable in HASS, but available on LIFX

I often get lights marked unavailable, subsequently not actionable for my adaptive lighting or automations. When this happens, the lights are still available via LIFX app and I can ping the lights no worries from HASS.

Wondering if there is a need to mark the light as unavailable from HASS? Or why it marks them unavailable? I'll extend that setting in the config and see what happens.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.