core: HA .89.1 owntracks integration broken

Home Assistant release with the issue: .89.1

Last working Home Assistant release (if known): .86.x

Operating environment (Hass.io/Docker/Windows/etc.): Raspbian

Component/platform: https://www.home-assistant.io/components/owntracks

Description of problem: After upgrading to .89.1 owntracks stopped reflecting changes. Owntracks reports status of 200. I deleted and re-added the owntracks integration.

I see the following errors in the log

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):

Setup as an integration. No additional configuration.

Traceback (if applicable):

2019-03-14 21:47:44 ERROR (MainThread) [homeassistant.components.owntracks.device_tracker] Exception in async_handle_message when dispatching 'owntracks': (<homeassistant.core.HomeAssistant object at 0x756dcef0>, <homeassistant.components.owntracks.OwnTracksContext object at 0x683b1b50>, {'_type': 'encrypted', 'data': 'unLuAHJyalwsd7OHoWBqexZzo1eKJWzFpI+Z9FWGlPNCeXR5yMg5MVZj8+mX+P0dHsGcfmWNh4oCJnRVeyCECfwafD0XWmZY/ajuvzK09yIQHKJiJX7f0eht9cFcQUaHioRYgzfepmUg4Tr2HSwnRXJvnABTyoycOa5vlD2FSPumOE2R87fSfngTm978x7K6Q3xe/FfsRJvu6wigwjwyzKZIYwn6cwWegJCgIT0uI/oro1jg', 'topic': 'owntracks/REDACTED/REDACTED'})

Traceback (most recent call last):
  File "/srv/hass/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 359, in async_handle_message
    await handler(hass, context, message)
  File "/srv/hass/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 322, in async_handle_encrypted_message
    message['data'])
  File "/srv/hass/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 121, in _decrypt_payload
    keylen, decrypt = get_cipher()
  File "/srv/hass/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 39, in get_cipher
    from nacl.secret import SecretBox
  File "/srv/hass/lib/python3.6/site-packages/nacl/secret.py", line 17, in <module>
    import nacl.bindings
  File "/srv/hass/lib/python3.6/site-packages/nacl/bindings/__init__.py", line 17, in <module>
    from nacl.bindings.crypto_aead import (
  File "/srv/hass/lib/python3.6/site-packages/nacl/bindings/crypto_aead.py", line 18, in <module>
    from nacl._sodium import ffi, lib
ImportError: /lib/arm-linux-gnueabihf/libc.so.6: version `GLIBC_2.25' not found (required by /srv/hass/lib/python3.6/site-packages/nacl/_sodium.abi3.so)

Additional information:

Owntracks configured in Android as described in the docs including encryption key.

Owntracks reports 200 as response.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 24 (18 by maintainers)

Most upvoted comments

pip install --no-binary :all: pynacl worked for me (after uninstalling pynacl first). HA 0.91.2 on Raspbian.

People that are having issues, please tell us what OS and version of it that you’re using.

To repro on your systems, you should be able to run python3 -c "from nacl.secret import SecretBox", so no need to get OwnTracks to report and look in logs.

Can you try to reinstall pynacl via pip uninstall pynacl the. pip install pynacl

If it doesn’t work, maybe try to install by SODIUM_INSTALL=system pip install pynacl

I am noticing this on 0.89.2, as well: upon reboot, all OwnTracks trackers go to not_home no matter what.

The device_tracker state restore was fixed some time back and is working fine for me (haven’t heard any complaints in the forums or on Discord).

I just noticed that Owntracks device trackers are not saving and restoring previous states. This is a big problem for automation trigger as the state is defaulting to not_home, even though before a restart of HA it was home.

Edit: After multiple restarts the state of the device tracker seems to be restored sometimes, but not always.

same issue on .89.2

arch armv7l
dev false
docker false
hassio false
os_name Linux
python_version 3.6.0
timezone Europe/Brussels
version 0.89.2
virtualenv true
Mar 14 09:53:23 raspi.lan hass[19393]: 2019-03-14 09:53:23 ERROR (MainThread) [homeassistant.components.owntracks.device_tracker] Exception in async_handle_message when dispatching 'owntracks': (<homeassistant.core.HomeAssistant object at 0x76a268f0>, <homeassistant.components.owntracks.OwnTracksContext object at 0x64134250>, {'_type': 'encrypted', 'data': 'DukdAN/RF1qdGoki2HAYzx2NQR5gU6N5DgPAEr6LVlr7K6QTg4rUosrk5AQ+gLsuOwdHfaRLeJylzuTh5UqgNCQ3JICMLyFc8TVTnvtJtwptpPn2SQs6ByyV8egqf+pKDh1gxbZXNzO8jK6i/gpBZIthcNPgFJ8CiP9GhRBVwOdWOmRqn+AQ7MONcb8PoBGDY6aFI98R/0tijGVxgYNyFPk+uiSF4s8f5m5nML7vXWNx1waW1usEkNclvlpsLhXFQ3iw', 'topic': 'owntracks/REDACTED/REDACTED'})
Mar 14 09:53:23 raspi.lan hass[19393]: Traceback (most recent call last):
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 359, in async_handle_message
Mar 14 09:53:23 raspi.lan hass[19393]:     await handler(hass, context, message)
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 322, in async_handle_encrypted_message
Mar 14 09:53:23 raspi.lan hass[19393]:     message['data'])
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 121, in _decrypt_payload
Mar 14 09:53:23 raspi.lan hass[19393]:     keylen, decrypt = get_cipher()
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/owntracks/device_tracker.py", line 39, in get_cipher
Mar 14 09:53:23 raspi.lan hass[19393]:     from nacl.secret import SecretBox
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/nacl/secret.py", line 17, in <module>
Mar 14 09:53:23 raspi.lan hass[19393]:     import nacl.bindings
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/nacl/bindings/__init__.py", line 17, in <module>
Mar 14 09:53:23 raspi.lan hass[19393]:     from nacl.bindings.crypto_aead import (
Mar 14 09:53:23 raspi.lan hass[19393]:   File "/srv/homeassistant/lib/python3.6/site-packages/nacl/bindings/crypto_aead.py", line 18, in <module>
Mar 14 09:53:23 raspi.lan hass[19393]:     from nacl._sodium import ffi, lib
Mar 14 09:53:23 raspi.lan hass[19393]: ImportError: /lib/arm-linux-gnueabihf/libc.so.6: version `GLIBC_2.25' not found (required by /srv/homeassistant/lib/python3.6/site-packages/nacl/_sodium.abi3.so)