The Google calendar not working

hi the google calendar stops working i im getting the message response error 400, i got this on the log

google: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 304, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 461, 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 "/usr/src/homeassistant/homeassistant/components/google/calendar.py", line 106, in update
    self.data.update()
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 240, in wrapper
    result = method(*args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/components/google/calendar.py", line 169, in update
    service, params = self._prepare_query()
  File "/usr/src/homeassistant/homeassistant/components/google/calendar.py", line 132, in _prepare_query
    service = self.calendar_service.get()
  File "/usr/src/homeassistant/homeassistant/components/google/__init__.py", line 346, in get
    http = credentials.authorize(httplib2.Http())
AttributeError: 'NoneType' object has no attribute 'authorize'

I had this issue - turns out I had to re-authorise with google.

Delete config/.google.token, then restart HA, it should set off a notification in HA that will take you to the google authentication page.

2 Likes

Thanks @zoogara - I had a similar issue where my node red automation kept saying I had -67 hours until my next work shift. Deleting and re-auth worked like a charm!

1 Like

Thanks, that work great