Skip to content

Unable to link to sensi site #80

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
hieronymousch opened this issue Jan 23, 2025 · 4 comments
Open

Unable to link to sensi site #80

hieronymousch opened this issue Jan 23, 2025 · 4 comments

Comments

@hieronymousch
Copy link

I'm unable to add my thermostats. I put in the token in the popup, get confirmation but then adding the devices fails.
Error in home assistant: "unable to authenticate, sensi integration is not ready"

Debug log:

`This error originated from a custom integration.

Logger: custom_components.sensi
Source: custom_components/sensi/init.py:55
integration: Sensi (documentation, issues)
First occurred: January 22, 2025 at 8:02:25 PM (13 occurrences)
Last logged: 11:12:06 AM

Unable to authenticate
Traceback (most recent call last):
File "/usr/local/lib/python3.13/site-packages/websockets/legacy/client.py", line 652, in await_impl
_transport, protocol = await self._create_connection()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.13/asyncio/base_events.py", line 1136, in create_connection
sock = await self._connect_sock(
^^^^^^^^^^^^^^^^^^^^^^^^^
exceptions, addrinfo, laddr_infos)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.13/asyncio/base_events.py", line 1039, in _connect_sock
await self.sock_connect(sock, address)
File "/usr/local/lib/python3.13/asyncio/selector_events.py", line 641, in sock_connect
return await fut
^^^^^^^^^
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 379, in _async_refresh
self.data = await self._async_update_data()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/sensi/coordinator.py", line 632, in _async_update_data
return await self._fetch_device_data()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/sensi/coordinator.py", line 664, in _fetch_device_data
async with websockets.client.connect(
~~~~~~~~~~~~~~~~~~~~~~~~~^
url, extra_headers=self._headers, ssl=_SSL_CONTEXT
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
) as websocket:
^
File "/usr/local/lib/python3.13/site-packages/websockets/legacy/client.py", line 633, in aenter
return await self
^^^^^^^^^^
File "/usr/local/lib/python3.13/site-packages/websockets/legacy/client.py", line 650, in await_impl
async with asyncio_timeout(self.open_timeout):
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.13/asyncio/timeouts.py", line 116, in aexit
raise TimeoutError from exc_val
TimeoutError

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

Traceback (most recent call last):
File "/config/custom_components/sensi/init.py", line 55, in async_setup_entry
await coordinator.async_config_entry_first_refresh()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 313, in async_config_entry_first_refresh
raise ex
homeassistant.exceptions.ConfigEntryNotReady`
'

I see DNS requests to oauth.sensiapi.io. & rt.sensiapi.io. on my router and replies.

Any tips would be greatly appreciated. This actually used to work.

@iprak
Copy link
Owner

iprak commented Jan 23, 2025

Double check the token .. it should be just the value and not quotes.

@hieronymousch
Copy link
Author

Did that... no joy

@hieronymousch
Copy link
Author

hieronymousch commented Jan 23, 2025

Tried it with 1.3.15. Get confirmation that configuration has been created and then the same initializing issue

Is there a way to manually review the config? Is it written somewhere on the filesystem? I'm running HA OS

@hieronymousch
Copy link
Author

OK, found it. Disabled ipv6 and works like a charm now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants