Giter Club home page Giter Club logo

ha_alpha_home's People

Contributors

arjenbos avatar chrismisker avatar schbenedikt avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

chrismisker

ha_alpha_home's Issues

Set up a heat pump

Let’s assume I have an Alpha Innotec heat pump. Then there are various configuration options such as: B. Gateway IP address, password, etc. What do you have to write in there so that everything is configured correctly?
What do you mean by gateway exactly? The Internet connection?
Unfortunately there is no proper description for this...
But as soon as I know, I might add these too.

Best regards,
schBenedikt

Feature request: Add set-back and comfort temperatures as input_numbers

Every few hours to few days, my temperature setpoint reverts to a default temperature. In the web UI of the control box, it is possible to change this value. It would be nice if this would be included in this integration.

I'm looking around a bit in the controller, and I can find the web UI where I can change the values. The value can be read out from http://CONTROLLER_IP/api/room/list and looking for the "groups" and then "rooms" key. Each room has the following data:

  {'id': 7,
   'appid': '01070002',
   'actualTemperature': 21,
   'isComfortMode': False,
   'desiredTemperature': 19.5,
   'roomstatus': 99,
   'desiredTempDay': 19.5,
   'desiredTempDay2': 18,
   'desiredTempNight': 18,
   'scheduleTempMin': 15,
   'scheduleTempMax': 28,
   'minTemperature': 18,
   'maxTemperature': 28,
   'cooling': False,
   'coolingEnabled': True,
   'imagepath': '/assets/images/room/default.png',
   'name': 'Woonkamer',
   'orderindex': 7,
   'originalName': 'Woonkamer',
   'status': 'problem',
   'groupid': 1,
   'windowPosition': 0}],
 'orderindex': 1}

The comfort temperature in the UI modifies both the desiredTempDay and desiredTemperature. The setback temperature in the UI modifies both the desiredTempDay2 and desiredTempNight.

Please let me know if you require additional information in order to add this.

Feature request: add device models

It would be nice to have device models display in the integration page. I think currently the most accurate model would be the module type, so sensor, sense_control or valve.

Climate entity incorrectly showing 'Cooling to Target'

First of all: thanks for the great work on this integration!

There is a small issue with the climate entities showing 'cooling to target' when cooling is enabled for that room. The controller API response is misinterpreted because "cooling": true and "coolingEnabled": true merely indicate that the room is allowed to use cooling. It does not mean that cooling is currently active for the room. It also does not mean that if "cooling" is false that the room is heating to the set target.

To solve this, I'd suggest updating the logic in climate.py

    def hvac_action(self) -> HVACAction | None:
        if not self.thermostat.cooling_enabled:
            return None

        if self.thermostat.cooling:
            return HVACAction.COOLING

        return HVACAction.HEATING

This whole logic could probably be removed as it provides no value. The default HVAC action of 'Auto' is correct: it simply shows the current and target temperature, the controller and gateway have no information if cooling or heating is currently active to achieve the target temperature.

Feature Request: possible to hide/show channels based on configuration

Great new feature to be able to see the state of the valves. I love it! Love the enthusiasm of the developer as well, thanks!

A feature request: is it possible to automatically show or hide the channels, based upon if they are configured or not? The Alpha Home valves always have 8 channels, but not all are used. If not used, the API does return a value, but it does nothing. So is it possible to hide these channels, when not configured?

Current temperature and battery cannot be read out on sense_control thermostat units

Great integration! I was thinking of improving my python skills and writing my own, but then I found this. Really happy with it! 😊

After installing and setting up, I could only change the temperature setpoint, not the current temperature or battery settings. After a few hours of digging, I managed a containment by modifying const.py and base_coordinator.py. The changes are below:

const.py changed to:

from homeassistant.const import Platform

DOMAIN = "alpha_innotec"

MANUFACTURER = "Alpha Innotec"

PLATFORMS = [
    Platform.SENSOR,
    Platform.CLIMATE,
]

MODULE_TYPE_FLOOR = "floor"
MODULE_TYPE_SENSOR = "sense_control" #changed from sensor

MODULE_TYPES = [
    MODULE_TYPE_FLOOR,
    MODULE_TYPE_SENSOR
]

base_coordinator.py changed line 43:

if module_details["type"] == MODULE_TYPE_SENSOR:
    current_temperature = module_details["currentTemperature"] #changed from actualTemperature
    battery_percentage = module_details["battery"]

Text is not displayed

The text doesn't appear here for me;
Does anyone know what is causing this or how to fix it?
Thanks!

Component won't connect to Alpha Home

Hello,

I have a Alpha Innotec heatpomp with the Luxtronix custom component installed.
I have it combined with an Alpha Home system with several thermostats and floor heating groups.
When trying to connect it won't and shown error "Unknown error occurred"

If i try to connect with the wrong password (controlbox) it shows "cannot_connect"
Home Assistant 2024.01.01
controlbox and gateway v 2.2.39533

How can i generate debug information to help you debug?

[1.1.0] Valves not updating

When the valves are first added to HA, the right state (open/closed) are shown. However, after a while, the state of the valve change ofcourse. I can see this happening when I'm viewing the Gateway wireless components page. However, I don't not see this state change happening in Home Assistant.
I also tried drastically changing the temperature in Home Assistant, so I'm sure the valves should open or close, but nothing happens to the state in Home Assistant. In real life, I can hear the valves opening or closing and I see this in the Gateway webpage as well, just not in Home Assistant.
I waited about 5 minutes and now it's about 10 minutes, and I still don't see it in Home Assistant.

Entities unavailable every night (connection refused)

I can see all entities of this integration go to status 'Unavailable' for a few minutes every night. It's always around 04:00, so curious to find out if this is something others are seeing this as well.

The logs show a few things, but the most important seems to be:

2023-11-01 03:48:14.940 ERROR (SyncWorker_1) [custom_components.alpha_innotec.gateway_api] Unable to fetch data from API: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/dbmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f60847ed0>: Failed to establish a new connection: [Errno 111] Connection refused'))

The full logs with all relevant lines is below, but it seems the integration cannot connect with the Gateway. As far as I can see the Gateway is available at that time. The Gateway also runs the latest firmware available (2.2.39533).

So not sure why the Gateway would refuse the connection every night at around 4 AM.

Full logs below:

2023-11-01 03:16:12.426 ERROR (SyncWorker_5) [custom_components.alpha_innotec.controller_api] Unable to fetch data from API: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    six.raise_from(e, None)
  File "<string>", line 3, in raise_from
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 462, in _make_request
    httplib_response = conn.getresponse()
                       ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 1378, in getresponse
    response.begin()
  File "/usr/local/lib/python3.11/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
                              ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 287, in _read_status
    raise RemoteDisconnected("Remote end closed connection without"
http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 799, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/retry.py", line 550, in increment
    raise six.reraise(type(error), error, _stacktrace)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/packages/six.py", line 769, in reraise
    raise value.with_traceback(tb)
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    six.raise_from(e, None)
  File "<string>", line 3, in raise_from
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 462, in _make_request
    httplib_response = conn.getresponse()
                       ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 1378, in getresponse
    response.begin()
  File "/usr/local/lib/python3.11/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
                              ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 287, in _read_status
    raise RemoteDisconnected("Remote end closed connection without"
urllib3.exceptions.ProtocolError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/alpha_innotec/controller_api.py", line 45, in call
    response = requests.post("http://{hostname}/{endpoint}".format(hostname=self.api_host, endpoint=endpoint),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
    return request("post", url, data=data, json=json, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 501, in send
    raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
2023-11-01 03:16:12.453 ERROR (MainThread) [custom_components.alpha_innotec.sensor] Unexpected error fetching Alpha Sensor data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/sensor.py", line 71, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 26, in get_thermostats
    room_list: dict = await hass.async_add_executor_job(controller_api.room_list)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/controller_api.py", line 97, in room_list
    return self.call("api/room/list")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/controller_api.py", line 59, in call
    if not json_response['success']:
           ~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
2023-11-01 03:16:17.513 ERROR (MainThread) [custom_components.alpha_innotec.climate] Unexpected error fetching Alpha Sensor data: Failed to get data
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/climate.py", line 73, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 21, in get_thermostats
    rooms: dict = await hass.async_add_executor_job(gateway_api.all_modules)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 87, in all_modules
    response = self.call("api/gateway/allmodules")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 70, in call
    raise Exception('Failed to get data')
Exception: Failed to get data
2023-11-01 03:16:45.148 ERROR (SyncWorker_2) [custom_components.alpha_innotec.controller_api] Unable to fetch data from API: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    six.raise_from(e, None)
  File "<string>", line 3, in raise_from
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 462, in _make_request
    httplib_response = conn.getresponse()
                       ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 1378, in getresponse
    response.begin()
  File "/usr/local/lib/python3.11/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
                              ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 287, in _read_status
    raise RemoteDisconnected("Remote end closed connection without"
http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 799, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/retry.py", line 550, in increment
    raise six.reraise(type(error), error, _stacktrace)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/packages/six.py", line 769, in reraise
    raise value.with_traceback(tb)
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    six.raise_from(e, None)
  File "<string>", line 3, in raise_from
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 462, in _make_request
    httplib_response = conn.getresponse()
                       ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 1378, in getresponse
    response.begin()
  File "/usr/local/lib/python3.11/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
                              ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/http/client.py", line 287, in _read_status
    raise RemoteDisconnected("Remote end closed connection without"
urllib3.exceptions.ProtocolError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/alpha_innotec/controller_api.py", line 45, in call
    response = requests.post("http://{hostname}/{endpoint}".format(hostname=self.api_host, endpoint=endpoint),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
    return request("post", url, data=data, json=json, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 501, in send
    raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
2023-11-01 03:16:45.175 ERROR (MainThread) [custom_components.alpha_innotec.sensor] Unexpected error fetching Alpha Sensor data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/sensor.py", line 71, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 26, in get_thermostats
    room_list: dict = await hass.async_add_executor_job(controller_api.room_list)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/controller_api.py", line 97, in room_list
    return self.call("api/room/list")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/controller_api.py", line 59, in call
    if not json_response['success']:
           ~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
2023-11-01 03:16:48.249 ERROR (MainThread) [custom_components.alpha_innotec.climate] Unexpected error fetching Alpha Sensor data: Failed to get data
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/climate.py", line 73, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 21, in get_thermostats
    rooms: dict = await hass.async_add_executor_job(gateway_api.all_modules)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 87, in all_modules
    response = self.call("api/gateway/allmodules")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 70, in call
    raise Exception('Failed to get data')
Exception: Failed to get data
2023-11-01 03:48:14.940 ERROR (SyncWorker_1) [custom_components.alpha_innotec.gateway_api] Unable to fetch data from API: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/dbmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f60847ed0>: Failed to establish a new connection: [Errno 111] Connection refused'))
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 174, in _new_conn
    conn = connection.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 95, in create_connection
    raise err
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 85, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 416, in _make_request
    conn.request(method, url, **httplib_request_kw)
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 244, in request
    super(HTTPConnection, self).request(method, url, body=body, headers=headers)
  File "/usr/local/lib/python3.11/http/client.py", line 1286, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1332, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1281, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1041, in _send_output
    self.send(msg)
  File "/usr/local/lib/python3.11/http/client.py", line 979, in send
    self.connect()
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 205, in connect
    conn = self._new_conn()
           ^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x7f60847ed0>: Failed to establish a new connection: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 799, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/dbmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f60847ed0>: Failed to establish a new connection: [Errno 111] Connection refused'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 54, in call
    response = requests.post("http://{hostname}/{endpoint}".format(hostname=self.api_host, endpoint=endpoint),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
    return request("post", url, data=data, json=json, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 519, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/dbmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f60847ed0>: Failed to establish a new connection: [Errno 111] Connection refused'))
2023-11-01 03:48:14.957 ERROR (MainThread) [custom_components.alpha_innotec.binary_sensor] Unexpected error fetching Alpha Innotec Binary Coordinator data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/binary_sensor.py", line 65, in _async_update_data
    db_modules: dict = await self.hass.async_add_executor_job(self.gateway_api.db_modules)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 93, in db_modules
    return self.call("api/gateway/dbmodules")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 69, in call
    if not json_response['success']:
           ~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
2023-11-01 03:48:25.815 ERROR (SyncWorker_6) [custom_components.alpha_innotec.gateway_api] Unable to fetch data from API: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6ad09c10>: Failed to establish a new connection: [Errno 111] Connection refused'))
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 174, in _new_conn
    conn = connection.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 95, in create_connection
    raise err
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 85, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 416, in _make_request
    conn.request(method, url, **httplib_request_kw)
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 244, in request
    super(HTTPConnection, self).request(method, url, body=body, headers=headers)
  File "/usr/local/lib/python3.11/http/client.py", line 1286, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1332, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1281, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1041, in _send_output
    self.send(msg)
  File "/usr/local/lib/python3.11/http/client.py", line 979, in send
    self.connect()
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 205, in connect
    conn = self._new_conn()
           ^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x7f6ad09c10>: Failed to establish a new connection: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 799, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6ad09c10>: Failed to establish a new connection: [Errno 111] Connection refused'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 54, in call
    response = requests.post("http://{hostname}/{endpoint}".format(hostname=self.api_host, endpoint=endpoint),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
    return request("post", url, data=data, json=json, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 519, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6ad09c10>: Failed to establish a new connection: [Errno 111] Connection refused'))
2023-11-01 03:48:25.835 ERROR (MainThread) [custom_components.alpha_innotec.sensor] Unexpected error fetching Alpha Sensor data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/sensor.py", line 71, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 21, in get_thermostats
    rooms: dict = await hass.async_add_executor_job(gateway_api.all_modules)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 87, in all_modules
    response = self.call("api/gateway/allmodules")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 69, in call
    if not json_response['success']:
           ~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
2023-11-01 03:48:28.950 ERROR (SyncWorker_3) [custom_components.alpha_innotec.gateway_api] Unable to fetch data from API: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6748a950>: Failed to establish a new connection: [Errno 111] Connection refused'))
Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 174, in _new_conn
    conn = connection.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 95, in create_connection
    raise err
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/connection.py", line 85, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 416, in _make_request
    conn.request(method, url, **httplib_request_kw)
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 244, in request
    super(HTTPConnection, self).request(method, url, body=body, headers=headers)
  File "/usr/local/lib/python3.11/http/client.py", line 1286, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1332, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1281, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "/usr/local/lib/python3.11/http/client.py", line 1041, in _send_output
    self.send(msg)
  File "/usr/local/lib/python3.11/http/client.py", line 979, in send
    self.connect()
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 205, in connect
    conn = self._new_conn()
           ^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x7f6748a950>: Failed to establish a new connection: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 799, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/urllib3/util/retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6748a950>: Failed to establish a new connection: [Errno 111] Connection refused'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 54, in call
    response = requests.post("http://{hostname}/{endpoint}".format(hostname=self.api_host, endpoint=endpoint),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
    return request("post", url, data=data, json=json, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 519, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='192.168.1.192', port=80): Max retries exceeded with url: /api/gateway/allmodules (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f6748a950>: Failed to establish a new connection: [Errno 111] Connection refused'))
2023-11-01 03:48:28.972 ERROR (MainThread) [custom_components.alpha_innotec.climate] Unexpected error fetching Alpha Sensor data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/climate.py", line 73, in _async_update_data
    return await self.get_thermostats(self.hass, self.gateway_api, self.controller_api)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 64, in get_thermostats
    raise exception
  File "/config/custom_components/alpha_innotec/base_coordinator.py", line 21, in get_thermostats
    rooms: dict = await hass.async_add_executor_job(gateway_api.all_modules)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 87, in all_modules
    response = self.call("api/gateway/allmodules")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/alpha_innotec/gateway_api.py", line 69, in call
    if not json_response['success']:
           ~~~~~~~~~~~~~^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable

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.