Tado API change

My Tado component stopped working one day ago.
I get this error:

  File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/core.py", line 1002, in _event_to_service_call
    await service_handler.func(service_call)
  File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/climate/__init__.py", line 392, in async_operation_set_service
    await climate.async_set_operation_mode(operation_mode)
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/climate/tado.py", line 228, in set_operation_mode
    self._control_heating()
  File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/climate/tado.py", line 350, in _control_heating
    self._store.set_zone_overlay(self.zone_id, CONST_OVERLAY_MANUAL)
  File "/srv/homeassistant/lib/python3.6/site-packages/homeassistant/components/tado.py", line 127, in set_zone_overlay
    self.tado.setZoneOverlay(zone_id, mode, temperature, duration)
  File "/srv/homeassistant/lib/python3.6/site-packages/PyTado/interface.py", line 278, in setZoneOverlay
    data = self._apiCall(cmd, "PUT", post_data, True)
  File "/srv/homeassistant/lib/python3.6/site-packages/PyTado/interface.py", line 81, in _apiCall
    response = self.opener.open(req)
  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 422: Unprocessable Entity

I found this issue at github but no soulution.
Looks like tado changed their api…

It’s fixed, thanks to @syssi but home assistant showing now “null” if climate state is off.
Ha

It looks like an edge-case. If you start Home Assistant while the heater is off the target temperature of the past is unknown. If you turn on the heater on and off again it should show a target temperature. In my case it’s working fine:

tado

Oh okay, I restarted my Home Assistant for some changes…
Thanks for your advice, again.

I am still getting the error HTTP 422 only when I try to change a TADO thermostat from Smart Schedule to OFF:

Error executing service <ServiceCall climate.set_operation_mode: operation_mode=Off, entity_id=['climate.cucina']>
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/homeassistant/core.py", line 1002, in _event_to_service_call
    await service_handler.func(service_call)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/__init__.py", line 393, in async_operation_set_service
    await climate.async_set_operation_mode(operation_mode)
  File "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/tado.py", line 228, in set_operation_mode
    self._control_heating()
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/tado.py", line 350, in _control_heating
    self._store.set_zone_overlay(self.zone_id, CONST_OVERLAY_MANUAL)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/tado.py", line 127, in set_zone_overlay
    self.tado.setZoneOverlay(zone_id, mode, temperature, duration)
  File "/usr/lib/python3.6/site-packages/PyTado/interface.py", line 278, in setZoneOverlay
    data = self._apiCall(cmd, "PUT", post_data)
  File "/usr/lib/python3.6/site-packages/PyTado/interface.py", line 81, in _apiCall
    response = self.opener.open(req)
  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 422: Unprocessable Entity

When I use other modes it is OK