custom-components / authenticated

A platform which allows you to get information about sucessfull logins to Home Assistant.
MIT License
82 stars 28 forks source link

Version 1 breaks sensor. No sensor created #39

Closed DavidFW1960 closed 5 years ago

DavidFW1960 commented 5 years ago

Version of the custom_component

Version 1.0 latest Describe the bug A clear and concise description of what the bug is. Version 1 breaks it and the sensor is not created log


authenticated: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 261, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 377, in async_device_update
    await self.hass.async_add_executor_job(self.update)
  File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/authenticated/sensor.py", line 142, in update
    ipaddress.lookup()
  File "/config/custom_components/authenticated/sensor.py", line 313, in lookup
    self.hostname = get_hostname(self.ip_address)
  File "/config/custom_components/authenticated/sensor.py", line 266, in get_hostname
    return socket.getfqdn(ip_address)
  File "/usr/local/lib/python3.7/socket.py", line 672, in getfqdn
    name = name.strip()
AttributeError: 'NoneType' object has no attribute 'strip'
ludeeus commented 5 years ago

Lol... That is the only part that did not change...

DavidFW1960 commented 5 years ago

Hahahahaha... yeah well it’s not working now....