Core: HA Adguard addon issue connecting to Adguard Home instance

Created on 23 Jul 2020  路  9Comments  路  Source: home-assistant/core

The problem

Unable to connect to Adguard Home instance running on a Linux machine.

Environment Adguard Instance

  • Debian 10 machine
  • AdGuard Home v0.103.0-beta3

    Environment

    • Home Assistant Core release with the issue: 0.113.0
    • Last working Home Assistant Core release (if known): 0.112.4
    • Operating environment (OS/Container/Supervised/Core): Supervised
    • Integration causing this issue: Adguard Home Addon

Problem-relevant configuration.yaml

none

Traceback/Error logs

```Log Details (ERROR)
Logger: aiohttp.server
Source: components/adguard/config_flow.py:87
First occurred: 1:15:19 PM (1 occurrences)
Last logged: 1:15:19 PM

Error handling request
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/aiohttp/web_protocol.py", line 418, in start
resp = await task
File "/usr/local/lib/python3.7/site-packages/aiohttp/web_app.py", line 458, in _handle
resp = await handler(request)
File "/usr/local/lib/python3.7/site-packages/aiohttp/web_middlewares.py", line 119, in impl
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/real_ip.py", line 39, in real_ip_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 127, in auth_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 129, in handle
result = await result
File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 145, in post
return await super().post(request, flow_id)
File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 60, in wrapper
result = await method(view, request, args, *kwargs)
File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 106, in post
result = await self._flow_mgr.async_configure(flow_id, data)
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 153, in async_configure
result = await self._async_handle_step(flow, cur_step["step_id"], user_input)
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 201, in _async_handle_step
result: Dict = await getattr(flow, method)(user_input)
File "/usr/src/homeassistant/homeassistant/components/adguard/config_flow.py", line 87, in async_step_user
if version and LooseVersion(MIN_ADGUARD_HOME_VERSION) > LooseVersion(version):
File "/usr/local/lib/python3.7/distutils/version.py", line 64, in __gt__
c = self._cmp(other)
File "/usr/local/lib/python3.7/distutils/version.py", line 337, in _cmp
if self.version < other.version:
TypeError: '<' not supported between instances of 'str' and 'int'

```

Additional information

error

adguard

Most helpful comment

@apedance Please don't stack or cross the beams on unrelated issues. It is highly confusing and is prone to lose focus on the issue at hand. Thanks 馃憤

The issue presented in this issue is known and the cause is clear. I hope so supply a fix for this shortly, however, I'm battling getting AdGuard 0.103 up and running in my environment for proper testing.

The AdGuard team is helpful and cooperative on this, so please bare with me.

All 9 comments

adguard documentation
adguard source
(message by IssueLinks)

Weird, seems an issue with the version number in beta3 of adguard Home.

Could you provide me the output of http://address.to.your.adguard.instance/control/status

?

Sure:

old
{"dns_addresses":["127.0.0.1","::1","192.168.1.86","172.17.0.1"],"dns_port":53,"http_port":3000,"language":"","protection_enabled":true,"running":true,"version":"v0.102.0"}

new
{"dns_addresses":["127.0.0.1","::1","192.168.1.86","172.17.0.1"],"dns_port":53,"http_port":3000,"language":"","protection_enabled":true,"running":true,"version":"0.103.0"}

Hey there @frenck, mind taking a look at this issue as its been labeled with an integration (adguard) you are listed as a codeowner for? Thanks!
(message by CodeOwnersMention)

Yup, this has been an issue since 0.103.0 of AdGuard Home.

Hello, just upgraded to HA supervised to 0.113.1 and my AdGuard addon broke.
I'm running AdGuard on a different device and it is in version 0.103.3.

Nothing in the release for HA that mentions this.
Is this a confirmed issue? Do we have a fix coming?
Thanks in advance.

HA log:

2020-07-25 11:50:57 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 192.168.XX.X for adguard
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 219, in async_setup
result = await component.async_setup_entry( # type: ignore
File "/usr/src/homeassistant/homeassistant/components/adguard/__init__.py", line 74, in async_setup_entry
if version and LooseVersion(MIN_ADGUARD_HOME_VERSION) > LooseVersion(version):
File "/usr/local/lib/python3.8/distutils/version.py", line 64, in __gt__
c = self._cmp(other)
File "/usr/local/lib/python3.8/distutils/version.py", line 337, in _cmp
if self.version < other.version:
TypeError: '<' not supported between instances of 'str' and 'int'

Hello, just upgraded to HA supervised to 0.113.1 and my AdGuard addon broke.
I'm running AdGuard on a different device and it is in version 0.103.3.

Nothing in the release for HA that mentions this.
Is this a confirmed issue? Do we have a fix coming?
Thanks in advance.

HA log:

2020-07-25 11:50:57 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 192.168.XX.X for adguard
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 219, in async_setup
result = await component.async_setup_entry( # type: ignore
File "/usr/src/homeassistant/homeassistant/components/adguard/init.py", line 74, in async_setup_entry
if version and LooseVersion(MIN_ADGUARD_HOME_VERSION) > LooseVersion(version):
File "/usr/local/lib/python3.8/distutils/version.py", line 64, in gt
c = self._cmp(other)
File "/usr/local/lib/python3.8/distutils/version.py", line 337, in _cmp
if self.version < other.version:
TypeError: '<' not supported between instances of 'str' and 'int'

The issue is known and @frenck has track of it.

Do you guys have to reconfigure the Adguard Addon everytime you restart Home Assistant?
--> https://github.com/home-assistant/core/issues/36197
This is the most annoying issue for me at least.

@apedance Please don't stack or cross the beams on unrelated issues. It is highly confusing and is prone to lose focus on the issue at hand. Thanks 馃憤

The issue presented in this issue is known and the cause is clear. I hope so supply a fix for this shortly, however, I'm battling getting AdGuard 0.103 up and running in my environment for proper testing.

The AdGuard team is helpful and cooperative on this, so please bare with me.

Thank you @frenck for all your hard work.

Was this page helpful?
0 / 5 - 0 ratings