Skip to content
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

Failed to set up #694

Closed
rjbungay opened this issue Nov 9, 2023 · 17 comments
Closed

Failed to set up #694

rjbungay opened this issue Nov 9, 2023 · 17 comments
Assignees
Labels
bug Something isn't working

Comments

@rjbungay
Copy link

rjbungay commented Nov 9, 2023

The problem

I have had the integration working fine for a year or so. In the last month or two it has stopped working with the error "failed to set up".
I have tried re-loading, deleting and re-installing etc.
I have also tried both "SSL" and normal connection.
The web interface of the router can be accessed with a browser using the login credentials I’m inputting when setting up.

Any help getting it working again would be appreciated.

Your device model

4G-AC55U

Firmware type

Stock

Firmware version

3.0.0.4.380_8102-gc321be4

Integration version with the issue

0.23.7

Method of the integration installation

HACS

What version and type of Home Assistant installation do you use

Core 2023.11.1

Is there anything useful in the logs?

Logger: homeassistant.config_entries
Source: config_entries.py:402 
First occurred: 20:22:46 (2 occurrences) 
Last logged: 20:33:25

Error setting up entry 192.168.1.1 for asusrouter
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 402, in async_setup
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/asusrouter/__init__.py", line 26, in async_setup_entry
    await router.setup()
  File "/config/custom_components/asusrouter/router.py", line 345, in setup
    await self.update_clients()
  File "/config/custom_components/asusrouter/router.py", line 389, in update_clients
    api_clients = await self.bridge.async_get_clients()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/asusrouter/bridge.py", line 278, in async_get_clients
    return await self._get_data(AsusData.CLIENTS, force=True)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/asusrouter/bridge.py", line 261, in _get_data
    raw = await self.api.async_get_data(datatype, force=force)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/asusrouter/asusrouter.py", line 453, in async_get_data
    data = await self.async_api_load(endpoint, request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/asusrouter/asusrouter.py", line 278, in async_api_load
    result = read(endpoint, content)
             ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/__init__.py", line 78, in read
    return submodule.read(content)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/update_clients.py", line 37, in read
    return read_legacy(match.group(1))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/update_clients.py", line 62, in read_legacy
    read_legacy_staticlist(clients, data.get("staticList"))
  File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/update_clients.py", line 193, in read_legacy_staticlist
    "name": client[2],
            ~~~~~~^^^
IndexError: list index out of range

Diagnostics information

No response

Additional information

No response

@rjbungay rjbungay added the bug Something isn't working label Nov 9, 2023
@github-project-automation github-project-automation bot moved this to Incoming in AsusRouter/HA Nov 9, 2023
@sleveille4
Copy link

sleveille4 commented Nov 10, 2023

Same issue for me, with Ax86u and 2023.11.1, stay "initialyzing" for many minutes then reports "Failed to setup".
Was working prior to update of add-on & ha a few days ago.
Trying to roll back ha to 2023.10.5

Edit: rolled back ha to 2023.10.5 but no succes, issue still present, how to roll back Asus router version ?

@Vaskivskyi
Copy link
Owner

Hello. Sorry to hear you are experiencing issues. I will check it

@rjbungay, this will be fixed in the backend library. Any other log error or always this one?

@sleveille4,

You can always install a different version of AsusRouter using HACS (redownload button in the menu for the repository). It allows going back for a couple of versions. If you would like go further in history, you would need to manually install the release of interest into your custom_components folder

image

P.S. @sleveille4, please, provide any error messages you are getting in the HA log (like the one posted in the original issue message)

@rjbungay
Copy link
Author

It always seems to be the same error

@sleveille4
Copy link

below is the HA log i get with DEBUG enabled, for some reason i do not have "download diagnostic" option in ASUSROUTER (maybe because it is stuck "initializing"?):
image
then a few moments later it's back to this:
image

AX86u is indeed at the correct IP and operating properly, can log in in HTTP etc...

2023-11-10 08:45:03.132 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 08:45:03.134 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 08:45:03.134 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 08:45:03.134 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f71b8aa10>`
2023-11-10 08:45:03.135 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 08:45:03.135 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 08:45:03.135 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 08:45:03.136 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 08:45:03.136 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:45:03.136 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:45:03.141 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:45:03.141 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 08:45:08.150 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:45:08.150 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:45:08.155 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:45:08.155 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 08:45:18.156 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:45:18.156 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:45:18.161 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:45:18.162 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 08:45:34.726 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: asusrouter
2023-11-10 08:45:38.163 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:45:38.163 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:45:38.168 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:45:38.168 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds
2023-11-10 08:46:11.720 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:46:11.720 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:46:12.750 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:46:12.750 DEBUG (MainThread) [asusrouter.connection] Will try again in 60.0 seconds
2023-11-10 08:46:13.471 WARNING (MainThread) [custom_components.govee] API is back online.
2023-11-10 08:46:38.632 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: asusrouter
2023-11-10 08:47:12.751 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:47:12.751 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:47:12.760 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:47:12.760 DEBUG (MainThread) [asusrouter.connection] Will try again in 120.0 seconds
2023-11-10 08:47:38.698 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: asusrouter
2023-11-10 08:48:38.768 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: asusrouter
2023-11-10 08:49:12.764 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:49:12.764 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:49:12.773 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:49:12.820 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 08:49:12.820 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 08:49:12.820 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 08:49:12.821 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f63b062d0>`
2023-11-10 08:49:12.824 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 08:49:12.825 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 08:49:12.825 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 08:49:12.825 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 08:49:12.825 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:49:12.825 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:49:12.890 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:49:12.890 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 08:49:17.891 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:49:17.892 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:49:17.897 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:49:17.897 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 08:49:27.899 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:49:27.899 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:49:27.907 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:49:27.907 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 08:49:47.908 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:49:47.909 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:49:47.916 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:49:47.916 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds
2023-11-10 08:50:17.917 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:50:17.918 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:50:17.926 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:50:17.926 DEBUG (MainThread) [asusrouter.connection] Will try again in 60.0 seconds
2023-11-10 08:51:17.928 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:51:17.928 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:51:17.936 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:51:17.936 DEBUG (MainThread) [asusrouter.connection] Will try again in 120.0 seconds
2023-11-10 08:53:17.938 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:53:17.938 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:53:17.946 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:53:28.111 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 08:53:28.112 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 08:53:28.112 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 08:53:28.112 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f643f0110>`
2023-11-10 08:53:28.112 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 08:53:28.113 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 08:53:28.113 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 08:53:28.113 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 08:53:28.113 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:53:28.114 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:53:28.123 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:53:28.123 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 08:53:33.124 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:53:33.125 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:53:33.133 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:53:33.133 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 08:53:43.135 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:53:43.135 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:53:43.146 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:53:43.146 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 08:54:03.148 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:54:03.149 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:54:03.159 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:54:03.160 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds
2023-11-10 08:54:33.161 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:54:33.161 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:54:33.169 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:54:33.169 DEBUG (MainThread) [asusrouter.connection] Will try again in 60.0 seconds
2023-11-10 08:55:33.170 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:55:33.171 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:55:33.179 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:55:33.180 DEBUG (MainThread) [asusrouter.connection] Will try again in 120.0 seconds
2023-11-10 08:57:33.181 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:57:33.181 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:57:33.190 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:57:53.543 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 08:57:53.544 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 08:57:53.545 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 08:57:53.545 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f5e919d50>`
2023-11-10 08:57:53.545 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 08:57:53.545 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 08:57:53.545 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 08:57:53.546 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 08:57:53.546 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:57:53.546 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:57:53.554 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:57:53.554 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 08:57:58.555 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:57:58.556 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:57:58.564 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:57:58.564 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 08:58:08.565 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:58:08.566 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:58:08.573 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:58:08.574 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 08:58:28.576 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:58:28.576 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:58:28.584 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:58:28.584 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds
2023-11-10 08:58:58.585 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:58:58.586 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:58:58.594 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:58:58.594 DEBUG (MainThread) [asusrouter.connection] Will try again in 60.0 seconds
2023-11-10 08:59:58.595 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 08:59:58.596 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 08:59:58.603 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 08:59:58.603 DEBUG (MainThread) [asusrouter.connection] Will try again in 120.0 seconds
2023-11-10 09:01:58.605 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:01:58.606 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:01:58.613 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:02:39.067 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 09:02:39.069 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 09:02:39.069 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 09:02:39.069 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f5fb8c9d0>`
2023-11-10 09:02:39.069 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 09:02:39.070 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 09:02:39.070 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 09:02:39.070 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 09:02:39.070 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:02:39.070 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:02:39.082 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:02:39.082 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 09:02:44.083 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:02:44.084 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:02:44.092 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:02:44.092 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 09:02:54.094 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:02:54.094 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:02:54.101 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:02:54.101 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 09:03:14.103 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:03:14.103 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:03:14.111 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:03:14.111 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds
2023-11-10 09:03:44.113 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:03:44.114 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:03:44.127 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:03:44.127 DEBUG (MainThread) [asusrouter.connection] Will try again in 60.0 seconds
2023-11-10 09:04:44.128 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:04:44.129 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:04:44.137 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:04:44.137 DEBUG (MainThread) [asusrouter.connection] Will try again in 120.0 seconds
2023-11-10 09:06:44.139 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:06:44.139 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:06:44.143 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:08:04.555 DEBUG (MainThread) [custom_components.asusrouter] Setting up entry
2023-11-10 09:08:04.556 DEBUG (MainThread) [asusrouter.asusrouter] Initializing a new interface to `192.168.2.1`
2023-11-10 09:08:04.556 DEBUG (MainThread) [asusrouter.connection] Initializing a new connection to `192.168.2.1`
2023-11-10 09:08:04.556 DEBUG (MainThread) [asusrouter.connection] Using session `<aiohttp.client.ClientSession object at 0x7f61885390>`
2023-11-10 09:08:04.556 DEBUG (MainThread) [asusrouter.connection] Using `http` and port `80`
2023-11-10 09:08:04.557 DEBUG (MainThread) [custom_components.asusrouter.router] Setting up router
2023-11-10 09:08:04.557 DEBUG (MainThread) [custom_components.asusrouter.bridge] Connecting to the API
2023-11-10 09:08:04.557 DEBUG (MainThread) [asusrouter.asusrouter] Triggered method async_connect
2023-11-10 09:08:04.557 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:08:04.558 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:08:04.567 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:08:04.567 DEBUG (MainThread) [asusrouter.connection] Will try again in 5.0 seconds
2023-11-10 09:08:09.570 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:08:09.570 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:08:09.580 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:08:09.580 DEBUG (MainThread) [asusrouter.connection] Will try again in 10.0 seconds
2023-11-10 09:08:19.582 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:08:19.582 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:08:19.590 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:08:19.590 DEBUG (MainThread) [asusrouter.connection] Will try again in 20.0 seconds
2023-11-10 09:08:39.591 DEBUG (MainThread) [asusrouter.connection] Initializing connection to 192.168.2.1
2023-11-10 09:08:39.592 DEBUG (MainThread) [asusrouter.connection] Requesting authorization
2023-11-10 09:08:39.599 DEBUG (MainThread) [asusrouter.connection] Connection failed
2023-11-10 09:08:39.599 DEBUG (MainThread) [asusrouter.connection] Will try again in 30.0 seconds

@Vaskivskyi
Copy link
Owner

@rjbungay, the issue you were having should be fixed in 0.24.0b0

@sleveille4, 0.24.0b0 is also adding better logging for the issue you are having. Please check your logs with it and open a new issue, so that we can track it properly and continue troubleshooting

@github-project-automation github-project-automation bot moved this from Incoming to Done in AsusRouter/HA Nov 12, 2023
@rjbungay
Copy link
Author

Unfortunately it still fails to set up

Logger: homeassistant.config_entries
Source: config_entries.py:402
First occurred: 07:18:30 (2 occurrences)
Last logged: 07:32:05

Error setting up entry 192.168.1.1 for asusrouter
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 402, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/asusrouter/init.py", line 26, in async_setup_entry
await router.setup()
File "/config/custom_components/asusrouter/router.py", line 352, in setup
await self._init_sensor_coordinators()
File "/config/custom_components/asusrouter/router.py", line 616, in _init_sensor_coordinators
available_sensors = await self.bridge.async_get_available_sensors()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/asusrouter/bridge.py", line 245, in async_get_available_sensors
SENSORS: await self._get_sensors_modern(AsusData.WIREGUARD_SERVER),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/asusrouter/bridge.py", line 507, in _get_sensors_modern
data = await self.api.async_get_data(datatype)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/asusrouter/asusrouter.py", line 539, in async_get_data
processed = process(
^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/init.py", line 113, in process
return submodule.process(data)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/hook.py", line 150, in process
state[AsusData.WIREGUARD_SERVER] = process_wireguard_server(data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/asusrouter/modules/endpoint/hook.py", line 615, in process_wireguard_server
wireguard.pop("status")
KeyError: 'status'

@Vaskivskyi Vaskivskyi reopened this Nov 13, 2023
@github-project-automation github-project-automation bot moved this from Done to Info Needed in AsusRouter/HA Nov 13, 2023
@sleveille4
Copy link

@rjbungay, the issue you were having should be fixed in 0.24.0b0

@sleveille4, 0.24.0b0 is also adding better logging for the issue you are having. Please check your logs with it and open a new issue, so that we can track it properly and continue troubleshooting

hi,
after rolling back then updating again, the issue is no longer present on my install so i can no longer provide further feedback on the issue since it now works. guess something went wrong when updating the first time.

@Vaskivskyi
Copy link
Owner

@rjbungay, please, check 0.24.0b1. This issue should also be fixed now. Hopefully, there won't be one more

@rjbungay
Copy link
Author

OK, I have now managed to set up the integration 0b1 without SSL enabled. With SSL enabled it just sat initialising forever. Thank you for fixing

@Vaskivskyi
Copy link
Owner

Are there some errors in the log when using SSL? Or does it just stuck?

@rjbungay
Copy link
Author

rjbungay commented Nov 15, 2023

No errors, it doesn't seem to get far enough to write to the log. It just stays as initialising.

@Vaskivskyi
Copy link
Owner

Hello, @rjbungay,

If you want, you can try running the new automated test of the data received from the device. This might help in understanding why you cannot use an SSL connection.

Details of how to run it are here -> #713

If you go step-by-step using SSL for the test, it can help to find out on which step communication breaks

If you are not interested or are fine with using non-SSL mode and everything works as you would expect in the integration, let me know - I'll close the issue

@rjbungay
Copy link
Author

rjbungay commented Nov 20, 2023 via email

@Vaskivskyi
Copy link
Owner

Hey. You need a terminal of any machine with Python to run this. E.g., your Home Assistant-running device, if you are running Core version of HA

@rjbungay
Copy link
Author

rjbungay commented Nov 20, 2023 via email

@Vaskivskyi
Copy link
Owner

Yes, sure. Windows installation of python is rather simple https://www.python.org/

@Vaskivskyi
Copy link
Owner

We seem to have solved all the parts of this issue both here and via email, so I will close this.

In case you'll be experiencing any other problem with AsusRouter, please, open a new issue ticket

@github-project-automation github-project-automation bot moved this from Info Needed to Done in AsusRouter/HA Nov 24, 2023
@Vaskivskyi Vaskivskyi moved this from Done to Stable in AsusRouter/HA Nov 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Stable
Development

No branches or pull requests

3 participants