tetele / hvac_group

Group together `climate` components for easy control
MIT License
23 stars 5 forks source link

Custom HVAC isn't showing modes or temp control #57

Closed MasterDevwi closed 6 months ago

MasterDevwi commented 6 months ago

System Health details

System Information

version core-2024.1.5
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.11.6
os_name Linux
os_version 6.1.63-haos-raspi
arch aarch64
timezone America/Los_Angeles
config_dir /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 4996 Installed Version | 1.34.0 Stage | running Available Repositories | 1387 Downloaded Repositories | 57
Home Assistant Cloud logged_in | true -- | -- subscription_expiration | November 19, 2024 at 4:00 PM relayer_connected | true relayer_region | us-east-1 remote_enabled | true remote_connected | true alexa_enabled | true google_enabled | true remote_server | us-east-1-6.ui.nabu.casa certificate_status | ready instance_id | c5c1cff36aed48bcac5a13c02c5e099c can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Home Assistant OS 11.4 -- | -- update_channel | stable supervisor_version | supervisor-2023.12.1 agent_version | 1.6.0 docker_version | 24.0.7 disk_total | 457.7 GB disk_used | 50.1 GB healthy | true supported | true board | rpi4-64 supervisor_api | ok version_api | ok installed_addons | File editor (5.7.0), Terminal & SSH (9.8.1), Mosquitto broker (6.4.0), Ring-MQTT with Video Streaming (5.6.3), Home Assistant Google Drive Backup (0.112.1), Node-RED (17.0.4), OneDrive Backup (2.2.4), ESPresense Companion (0.6.4), Studio Code Server (5.15.0), chrony (3.0.1), Advanced SSH & Web Terminal (17.0.5), MQTT Explorer (browser-1.0.3), Govee to MQTT Bridge (2024.01.24-ea3cd430)
Dashboards dashboards | 3 -- | -- resources | 41 views | 13 mode | storage
Recorder oldest_recorder_run | January 27, 2024 at 5:00 AM -- | -- current_recorder_run | January 31, 2024 at 5:31 PM estimated_db_size | 2193.75 MiB database_engine | sqlite database_version | 3.41.2
Spotify api_endpoint_reachable | ok -- | --

Checklist

Describe the issue

I have a Flair thermostat that controls a number of other room-specific thermostats. I can control the mode (heat, cool, heat/cool, or off) and the set temperature, but the current temperature isn't shown:

image

I'm using HVAC Group to try to solve this by wrapping the Flair thermostat with a custom temperature sensor that has the current home temp. For some reason, I can only switch between the heat/cool and off modes. And there's no way to set the temperature.

image

I believe I have all of the settings correct, so I'm worried this is a bug. But maybe I'm missing something?

image

Reproduction steps

  1. Install Flair integration
  2. Use the Flair Structure as both the heating thermostat and the cooling thermostat Note: Steps 1 and 2 may be able to be skipped by using another thermostat which also doesn't have a temperature attribute
  3. Add a custom sensor that takes the average of the individual Flair room thermostats
  4. The finished HVAC group is missing heat and cool modes, as well as the ability to set the temperature

Debug logs

2024-02-02 11:58:38.909 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration tcl_tv_remote which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.911 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration hass_agent which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.913 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration o365 which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.916 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration flair which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.919 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration custom_icons which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.919 ERROR (SyncWorker_1) [homeassistant.loader] The custom integration 'custom_icons' does not have a version key in the manifest file and was blocked from loading. See https://developers.home-assistant.io/blog/2021/01/29/custom-integration-changes#versions for more details
2024-02-02 11:58:38.921 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration smartlife which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.923 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration zha_toolkit which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.927 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration alexa_media which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.929 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration localtuya which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.932 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration fontawesome which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.935 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration simpleicons which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.939 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration everlights3 which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.940 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration virtual_keys which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.943 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration watchman which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.946 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.950 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration hvac_group which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.953 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration ui_lovelace_minimalist which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.956 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration browser_mod which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.958 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration lightener which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:58:38.960 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration tesla_custom which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-02-02 11:59:14.112 WARNING (MainThread) [zhaquirks] Loaded custom quirks. Please contribute them to https://github.com/zigpy/zha-device-handlers
2024-02-02 11:59:16.117 ERROR (Thread-7) [tuya_iot] error while get mqtt config
2024-02-02 11:59:16.119 ERROR (Thread-7) [root] Uncaught thread exception
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/threading.py", line 1045, in _bootstrap_inner
    self.run()
  File "/usr/local/lib/python3.11/site-packages/tuya_iot/openmq.py", line 161, in run
    time.sleep(self.mq_config.expire_time - 60)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'expire_time'
2024-02-02 11:59:16.191 WARNING (MainThread) [slixmpp.stringprep] Using slower stringprep, consider compiling the faster cython/libidn one.
2024-02-02 11:59:16.343 ERROR (SyncWorker_2) [roombapy.remote_client] Can't connect to 192.168.7.230, error: [Errno 113] Host is unreachable
2024-02-02 11:59:16.344 ERROR (SyncWorker_2) [roombapy.remote_client] Unable to connect to 192.168.7.230
2024-02-02 11:59:23.743 ERROR (MainThread) [homeassistant.components.light] Error while setting up everlights platform for light
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 360, in _async_setup_platform
    await asyncio.shield(task)
  File "/usr/src/homeassistant/homeassistant/components/everlights/light.py", line 61, in async_setup_platform
    status = await api.get_status()
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pyeverlights/__init__.py", line 52, in get_status
    resp = await self._fetch('/status/get')
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pyeverlights/__init__.py", line 40, in _fetch
    data = await response.json()
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.py", line 71, in json
    return await super().json(*args, loads=loads, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1165, in json
    raise ContentTypeError(
aiohttp.client_exceptions.ContentTypeError: 0, message='Attempt to decode JSON with unexpected mimetype: text/html;charset=utf-8', url=URL('http://192.168.7.247/status/get')
2024-02-02 11:59:23.821 ERROR (MainThread) [homeassistant.components.climate] Error adding entities for domain climate with platform hvac_group
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 507, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 752, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1281, in add_to_platform_finish
    await self.async_added_to_hass()
  File "/config/custom_components/hvac_group/climate.py", line 672, in async_added_to_hass
    await self.async_update_temperature_sensor(
  File "/config/custom_components/hvac_group/climate.py", line 935, in async_update_temperature_sensor
    float(new_temperature) if new_temperature is not None else new_temperature
    ^^^^^^^^^^^^^^^^^^^^^^
ValueError: could not convert string to float: 'unknown'
2024-02-02 11:59:23.851 ERROR (MainThread) [homeassistant.components.climate] Error while setting up hvac_group platform for climate
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 368, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 507, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 752, in _async_add_entity
    await entity.add_to_platform_finish()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1281, in add_to_platform_finish
    await self.async_added_to_hass()
  File "/config/custom_components/hvac_group/climate.py", line 672, in async_added_to_hass
    await self.async_update_temperature_sensor(
  File "/config/custom_components/hvac_group/climate.py", line 935, in async_update_temperature_sensor
    float(new_temperature) if new_temperature is not None else new_temperature
    ^^^^^^^^^^^^^^^^^^^^^^
ValueError: could not convert string to float: 'unknown'
2024-02-02 11:59:26.966 WARNING (MainThread) [homeassistant.setup] Setup of o365 is taking over 10 seconds.
2024-02-02 11:59:42.463 WARNING (MainThread) [zigpy.application] Zigbee channel 15 utilization is 98.43%!
2024-02-02 11:59:42.463 WARNING (MainThread) [zigpy.application] If you are having problems joining new devices, are missing sensor updates, or have issues keeping devices joined, ensure your coordinator is away from interference sources such as USB 3.0 devices, SSDs, WiFi routers, etc.
2024-02-02 11:59:46.109 ERROR (MainThread) [homeassistant.components.automation] Platform automation does not generate unique IDs. ID 1673808330040 already exists - ignoring automation.roombas_bin_full
2024-02-02 11:59:46.144 ERROR (MainThread) [homeassistant.components.automation] Platform automation does not generate unique IDs. ID 1692232918393 already exists - ignoring automation.clear_bedroom_tv_muted_state
2024-02-02 11:59:49.018 ERROR (MainThread) [homeassistant.helpers.event] Error while processing template: Template<template=({{ (state_attr('light.bedroom_fan_switch', 'brightness') / 255 * 100) | int }}) renders=2>
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 567, in async_render
    render_result = _render_with_context(self.template, compiled, **kwargs)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 2305, in _render_with_context
    return template.render(**kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/jinja2/environment.py", line 1301, in render
    self.environment.handle_exception()
  File "/usr/local/lib/python3.11/site-packages/jinja2/environment.py", line 936, in handle_exception
    raise rewrite_traceback_stack(source=source)
  File "<template>", line 1, in top-level template code
TypeError: unsupported operand type(s) for /: 'NoneType' and 'int'

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

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 693, in async_render_to_info
    render_info._result = self.async_render(
                          ^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 569, in async_render
    raise TemplateError(err) from err
homeassistant.exceptions.TemplateError: TypeError: unsupported operand type(s) for /: 'NoneType' and 'int'
2024-02-02 11:59:49.031 ERROR (MainThread) [homeassistant.components.template.template_entity] TemplateError('TypeError: unsupported operand type(s) for /: 'NoneType' and 'int'') while processing template 'Template<template=({{ (state_attr('light.bedroom_fan_switch', 'brightness') / 255 * 100) | int }}) renders=4>' for attribute '_percentage' in entity 'fan.bedroom_fan'
2024-02-02 11:59:49.033 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: 'off' is undefined when rendering '{{ off }}'
2024-02-02 11:59:49.033 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: 'off' is undefined when rendering '{{ off }}'
2024-02-02 11:59:49.034 ERROR (MainThread) [homeassistant.components.template.light] Received invalid light is_on state:  for entity light.guest_room_ceiling_switch_light. Expected: on, off, true, false
2024-02-02 11:59:56.263 INFO (MainThread) [backoff] Backing off async_request(...) for 0.8s (tesla_wall_connector.exceptions.WallConnectorConnectionTimeoutError: Timeout while connecting to Wall Connector at 192.168.7.48)
2024-02-02 12:00:05.095 ERROR (MainThread) [backoff] Giving up async_request(...) after 3 tries (tesla_wall_connector.exceptions.WallConnectorConnectionTimeoutError: Timeout while connecting to Wall Connector at 192.168.7.48)
2024-02-02 12:00:06.955 ERROR (MainThread) [pyhap.hap_handler] HASS Bridge: Client ('192.168.7.136', 63335) with uuid c4535657-eb4f-4080-9001-96d38a16bfc0 attempted pair verify without being paired first (public_key=f49661e9e70a529ea25dad8fb612d576da57be1ddecd79c72c6e670de553fd55, paired clients={UUID('638f887a-bf4a-4d2e-99ce-0e64b9cf28e4'): '81e11bad750c830286d815296b41f8fb8cd723fbeed2023ffa0be98d3352a520'}).
2024-02-02 12:00:10.426 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:10.427 WARNING (MainThread) [homeassistant.components.automation.switch_notification_patio_ceiling] Switch Notification: Patio Ceiling: Already running
2024-02-02 12:00:10.500 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:10.851 WARNING (MainThread) [homeassistant.components.automation.switch_notification_entryway_pendant] Switch Notification: Entryway Pendant: Already running
2024-02-02 12:00:16.891 ERROR (SyncWorker_31) [roombapy.remote_client] Can't connect to 192.168.7.230, error: [Errno 113] Host is unreachable
2024-02-02 12:00:19.964 ERROR (SyncWorker_31) [roombapy.remote_client] Can't connect to 192.168.7.230, error: [Errno 113] Host is unreachable
2024-02-02 12:00:36.601 ERROR (MainThread) [pyhap.hap_handler] HASS Bridge: Client ('192.168.7.136', 63347) with uuid c4535657-eb4f-4080-9001-96d38a16bfc0 attempted pair verify without being paired first (public_key=1e02606f5b614d7fae45a32bcff2ce0665e7d3bbe91bbcbeb86b56381a59623c, paired clients={UUID('638f887a-bf4a-4d2e-99ce-0e64b9cf28e4'): '81e11bad750c830286d815296b41f8fb8cd723fbeed2023ffa0be98d3352a520'}).
2024-02-02 12:00:39.044 ERROR (MainThread) [custom_components.tesla_custom] Error fetching tesla_custom data: Error communicating with API: 
2024-02-02 12:00:40.236 ERROR (MainThread) [pyhap.hap_handler] HASS Bridge: Client ('192.168.7.136', 63348) with uuid c4535657-eb4f-4080-9001-96d38a16bfc0 attempted pair verify without being paired first (public_key=d12aecdd4fa72eea6168a9186b9a2267be14004ccb5f638eb957af4d8e91475d, paired clients={UUID('638f887a-bf4a-4d2e-99ce-0e64b9cf28e4'): '81e11bad750c830286d815296b41f8fb8cd723fbeed2023ffa0be98d3352a520'}).
2024-02-02 12:00:40.315 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:40.316 WARNING (MainThread) [homeassistant.components.automation.switch_notification_patio_ceiling] Switch Notification: Patio Ceiling: Already running
2024-02-02 12:00:40.348 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:40.350 WARNING (MainThread) [homeassistant.components.automation.switch_notification_entryway_pendant] Switch Notification: Entryway Pendant: Already running
2024-02-02 12:00:42.669 WARNING (MainThread) [homeassistant.components.automation.switch_notification_patio_ceiling] Switch Notification: Patio Ceiling: Already running
2024-02-02 12:00:42.671 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:42.671 WARNING (MainThread) [homeassistant.components.automation.switch_notification_entryway_pendant] Switch Notification: Entryway Pendant: Already running
2024-02-02 12:00:42.672 WARNING (MainThread) [homeassistant.components.automation.switch_notification_patio_ceiling] Switch Notification: Patio Ceiling: Already running
2024-02-02 12:00:42.681 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:42.682 WARNING (MainThread) [homeassistant.components.automation.switch_notification_patio_ceiling] Switch Notification: Patio Ceiling: Already running
2024-02-02 12:00:42.702 WARNING (MainThread) [homeassistant.components.automation.alarm_status_reminder] Alarm Status Reminder: Already running
2024-02-02 12:00:42.741 WARNING (MainThread) [homeassistant.components.automation.switch_notification_entryway_pendant] Switch Notification: Entryway Pendant: Already running
2024-02-02 12:01:48.636 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/cluster_handlers/__init__.py", line 64, in wrap_zigpy_exceptions
    yield
  File "/usr/src/homeassistant/homeassistant/components/zha/core/cluster_handlers/__init__.py", line 84, in wrapper
    return await RETRYABLE_REQUEST_DECORATOR(func)(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/zigpy/util.py", line 131, in retry
    return await func()
           ^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/zigpy/zcl/__init__.py", line 377, in request
    return await self._endpoint.request(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/zigpy/endpoint.py", line 253, in request
    return await self.device.request(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/zigpy/device.py", line 323, in request
    await send_request()
  File "/usr/local/lib/python3.11/site-packages/zigpy/application.py", line 833, in request
    await self.send_packet(
  File "/usr/local/lib/python3.11/site-packages/bellows/zigbee/application.py", line 931, in send_packet
    raise zigpy.exceptions.DeliveryError(
zigpy.exceptions.DeliveryError: Failed to deliver message: <EmberStatus.DELIVERY_FAILED: 102>

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

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 594, in _async_run
    return await self.script.async_run(script_vars, context)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1587, in async_run
    return await asyncio.shield(run.async_run())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 426, in async_run
    await self._async_step(log_exceptions=False)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 479, in _async_step
    self._handle_exception(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 502, in _handle_exception
    raise exception
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 476, in _async_step
    await getattr(self, handler)()
  File "/usr/src/homeassistant/homeassistant/helpers/trace.py", line 272, in async_wrapper
    await func(*args)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 906, in _async_repeat_step
    await async_run_sequence(iteration)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 832, in async_run_sequence
    await self._async_run_script(script)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1078, in _async_run_script
    await self._async_run_long_action(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 675, in _async_run_long_action
    return long_task.result()
           ^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1587, in async_run
    return await asyncio.shield(run.async_run())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 426, in async_run
    await self._async_step(log_exceptions=False)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 479, in _async_step
    self._handle_exception(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 502, in _handle_exception
    raise exception
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 476, in _async_step
    await getattr(self, handler)()
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 713, in _async_call_service_step
    response_data = await self._async_run_long_action(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 675, in _async_run_long_action
    return long_task.result()
           ^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2149, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2186, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 272, in handle_service
    return await service.entity_service_call(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 882, in entity_service_call
    single_response = await _handle_entity_call(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 952, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 624, in async_handle_light_on_service
    await light.async_turn_on(**filter_turn_on_params(light, params))
  File "/usr/src/homeassistant/homeassistant/components/zha/light.py", line 336, in async_turn_on
    result = await self._level_cluster_handler.move_to_level_with_on_off(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/zha/core/cluster_handlers/__init__.py", line 83, in wrapper
    with wrap_zigpy_exceptions():
  File "/usr/local/lib/python3.11/contextlib.py", line 155, in __exit__
    self.gen.throw(typ, value, traceback)
  File "/usr/src/homeassistant/homeassistant/components/zha/core/cluster_handlers/__init__.py", line 75, in wrap_zigpy_exceptions
    raise HomeAssistantError(message) from exc
homeassistant.exceptions.HomeAssistantError: Failed to send request: Failed to deliver message: <EmberStatus.DELIVERY_FAILED: 102>

Diagnostics dump

No response

tetele commented 6 months ago

I've almost completely re-written the integration and I'm hoping it's much more robust now. There's a 0.2.0-beta version you could try (but you have to enable beta versions in HACS).

This issue was most likely fixed in #62 but please reopen it if it's not.

MasterDevwi commented 5 months ago

I just updated to v0.2.0. After deleting and re-adding the custom HVAC entity, I can now select Heat or Cool, as well as attempt to set the temperature.

image

Unfortunately, attempting to change the mode or set the temperature throws the following error:

Logger: homeassistant.components.websocket_api.http.connection Source: components/websocket_api/commands.py:240 Integration: Home Assistant WebSocket API (documentation, issues) First occurred: 12:31:52 PM (4 occurrences) Last logged: 12:33:01 PM

[547469945024] Flair server response content-type is not json: Internal Server Error

Internal Server Error

Traceback (most recent call last): File "/usr/local/lib/python3.12/site-packages/flairaio/flair_client.py", line 559, in _response response: dict[str, Any] = await resp.json() ^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.py", line 71, in json return await super().json(*args, loads=loads, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/aiohttp/client_reqrep.py", line 1166, in json raise ContentTypeError( aiohttp.client_exceptions.ContentTypeError: 0, message='Attempt to decode JSON with unexpected mimetype: text/html', url=URL('https://api.flair.co/api/structures/56658')

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

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 240, in handle_call_service response = await hass.services.async_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2279, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2316, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 962, in _handle_entity_call result = await task ^^^^^^^^^^ File "/config/custom_components/hvac_group/climate.py", line 1003, in async_set_hvac_mode await self.async_commit_state_if_running(update_actuators=True) File "/config/custom_components/hvac_group/climate.py", line 540, in async_commit_state_if_running await self._heaters.async_commit() File "/config/custom_components/hvac_group/actuator.py", line 368, in async_commit await actuator.async_commit() File "/config/custom_components/hvac_group/actuator.py", line 217, in async_commit await self._action_to_commit File "/config/custom_components/hvac_group/actuator.py", line 374, in create_coro return await function(*args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/hvac_group/actuator.py", line 170, in _async_call_climate_service await self.hass.services.async_call( File "/usr/src/homeassistant/homeassistant/core.py", line 2279, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2316, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 962, in _handle_entity_call result = await task ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/climate/init.py", line 835, in async_service_temperature_set await entity.async_set_temperature(kwargs) File "/config/custom_components/flair/climate.py", line 259, in async_set_temperature await self.coordinator.client.update('structures', self.structure_data.id, attributes=attributes, relationships={}) File "/usr/local/lib/python3.12/site-packages/flairaio/flair_client.py", line 479, in update return await self._patch(request_url, request_data) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/flairaio/flair_client.py", line 543, in _patch return await self._response(resp) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/flairaio/flair_client.py", line 575, in _response raise FlairError(f'Flair server response content-type is not json: {text}') from cte flairaio.exceptions.FlairError: Flair server response content-type is not json:

Internal Server Error

Internal Server Error