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

Update for Netatmo binary sensors fails #9723

Closed
e6on opened this issue Oct 7, 2017 · 2 comments · Fixed by #10631
Closed

Update for Netatmo binary sensors fails #9723

e6on opened this issue Oct 7, 2017 · 2 comments · Fixed by #10631

Comments

@e6on
Copy link

e6on commented Oct 7, 2017

Make sure you are running the latest version of Home Assistant before reporting an issue.

You should only file an issue if you found a bug. Feature and enhancement requests should go in the Feature Requests section of our community forum:

Home Assistant release (hass --version):
0.54 on Hass.io 1.1

Python release (python3 --version):
3.6

Component/platform:
binary_sensor:
platform: netatmo

Description of problem:
The sensor is working fine, but the log is full of errors like that:

2017-10-01 01:27:10 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_someone_unknown fails
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 225, in async_update_ha_state
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 170, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden
**2017-10-01 01:27:10 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_motion fails**
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 225, in async_update_ha_state
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 170, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden
**2017-10-01 01:27:11 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_someone_known fails**
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 225, in async_update_ha_state
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 170, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

Expected:
no errors in the log

Problem-relevant configuration.yaml entries and steps to reproduce:

# Netatmo Camera Sensor
binary_sensor:
  platform: netatmo
  1. just define the sensor in the config
  2. start home assistant
  3. keep it running for at least 2 days
    HA started at 2017-09-30 22:26:46
    1st error at 2017-10-01 01:27:10

Traceback (if applicable):

Additional info:

@e6on
Copy link
Author

e6on commented Oct 28, 2017

Upgraded HA to 0.56.2 but still getting the same errors.

@e6on
Copy link
Author

e6on commented Nov 26, 2017

Upgraded HA to 0.58.1 and getting the same errors.

2017-11-26 01:33:04 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_motion fails
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 199, in async_update_ha_state
    yield from self.async_device_update()
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 306, in async_device_update
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 168, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden
2017-11-26 01:33:05 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_someone_known fails
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 199, in async_update_ha_state
    yield from self.async_device_update()
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 306, in async_device_update
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 168, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden
2017-11-26 01:33:05 ERROR (MainThread) [homeassistant.helpers.entity] Update for binary_sensor.koducam_someone_unknown fails
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 199, in async_update_ha_state
    yield from self.async_device_update()
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 306, in async_device_update
    yield from self.hass.async_add_job(self.update)
  File "/usr/lib/python3.6/asyncio/futures.py", line 331, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.6/asyncio/tasks.py", line 244, in _wakeup
    future.result()
  File "/usr/lib/python3.6/asyncio/futures.py", line 244, in result
    raise self._exception
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/binary_sensor/netatmo.py", line 168, in update
    self._data.update_event()
  File "/usr/lib/python3.6/site-packages/homeassistant/util/__init__.py", line 306, in wrapper
    result = method(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/netatmo.py", line 121, in update_event
    home=self.home, cameratype=self.camera_type)
  File "/usr/lib/python3.6/site-packages/smart_home/Camera.py", line 252, in updateEvent
    resp = postRequest(_GETEVENTSUNTIL_REQ, postParams, body_size=None)
  File "/usr/lib/python3.6/site-packages/smart_home/__init__.py", line 27, in postRequest
    resp = urllib.request.urlopen(req, params).read(body_size).decode("utf-8")
  File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden

@home-assistant home-assistant locked and limited conversation to collaborators Mar 2, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant