Google and Waze travel time stopped working and cant configure it again

For some years I’ve had Google and Waze travel time set up using configuration.yaml.
It’s using device_tracker.my_iPhone as origin and sensor.dest_adress as destination.
Sensor.dest_adress changes depending if I’m at home or work etc.

After some update, I believe it was 2022.02 it stopped working and booth became “unavailable”
I see that the configuration was moved from yaml to UI.

I have tried to remove integration, also removing in configuration.yaml and try to add it again but I keep getting “unexpected error”.
Tried to restart etc numerous times.

I have also tried using fixed adress but still “unexpected error”

emphasized textLogger: aiohttp.server
Source: components/google_travel_time/helpers.py:15
First occurred: 10:58:59 AM (2 occurrences)
Last logged: 10:59:14 AM

Error handling request
Traceback (most recent call last):
File “/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py”, line 435, in _handle_request
resp = await request_handler(request)
File “/usr/local/lib/python3.9/site-packages/aiohttp/web_app.py”, line 504, in _handle
resp = await handler(request)
File “/usr/local/lib/python3.9/site-packages/aiohttp/web_middlewares.py”, line 117, in impl
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/security_filter.py”, line 60, in security_filter_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/forwarded.py”, line 98, in forwarded_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/request_context.py”, line 28, in request_context_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/ban.py”, line 79, in ban_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/auth.py”, line 219, in auth_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/view.py”, line 137, in handle
result = await result
File “/usr/src/homeassistant/homeassistant/components/config/config_entries.py”, line 164, in post
return await super().post(request, flow_id)
File “/usr/src/homeassistant/homeassistant/components/http/data_validator.py”, line 62, in wrapper
result = await method(view, request, *args, **kwargs)
File “/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py”, line 111, in post
result = await self._flow_mgr.async_configure(flow_id, data)
File “/usr/src/homeassistant/homeassistant/data_entry_flow.py”, line 252, in async_configure
result = await self._async_handle_step(flow, cur_step[“step_id”], user_input)
File “/usr/src/homeassistant/homeassistant/data_entry_flow.py”, line 325, in _async_handle_step
result: FlowResult = await getattr(flow, method)(user_input)
File “/usr/src/homeassistant/homeassistant/components/google_travel_time/config_flow.py”, line 130, in async_step_user
if await self.hass.async_add_executor_job(
File “/usr/local/lib/python3.9/concurrent/futures/thread.py”, line 52, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/src/homeassistant/homeassistant/components/google_travel_time/helpers.py”, line 15, in is_valid_config_entry
distance_matrix(client, origin, destination, mode=“driving”)
File “/usr/local/lib/python3.9/site-packages/googlemaps/distance_matrix.py”, line 90, in distance_matrix
“destinations”: convert.location_list(destinations)
File “/usr/local/lib/python3.9/site-packages/googlemaps/convert.py”, line 128, in location_list
return “|”.join([latlng(location) for location in as_list(arg)])
File “/usr/local/lib/python3.9/site-packages/googlemaps/convert.py”, line 128, in
emphasized text

This was fixed in the Beta release. I have a different issue. It shows my distance and time as the wrong values.

I had the same issue. Just figured it out by deleting the existing config under integrations.
Made a new one and for me I used source as person and destination as zone.home where home is my zone. Works again now. I’m running core-2022.2.6 FYI.

I deleted mine also and used the Lat / lon for the destination and the numbers are now correct. Since I am new to this I am trying to understand the doc:

https://www.home-assistant.io/integrations/waze_travel_time/

Do you add the input select and the template to your configuartion.yaml file?

Is this integration only used from one origin? I.e. home to where every?

I just use it for time to home from wherever I may be. All config is done through the UI now.
I still have the commented out entries in my configuration.yaml as I couldn’t recall and just searched it. Hehe. I guess I can delete that now.

For destination I was using “dest_adress” but as I said it is not working anymore :frowning:

I had this in configuration.yaml:

  - platform: template
    sensors:
      dest_address:
        value_template: >-
           {% if is_state('person.me', 'home') %}
             My_work_adress
           {%- else -%}
             My_home_adress
           {%- endif %}


  - platform: google_travel_time
    name: google travel time
    api_key: XXXXXXXXXXXXXXXXXXXXXXX
    origin: device_tracker.my_iPhone
    destination: sensor.dest_address

#Waze platform
  - platform: waze_travel_time
    name: waze travel time
    origin: device_tracker.my_iPhone
    destination: sensor.dest_address
    region: 'EU'

I hope they can fix so UI configuration works again

I believe this is fixed in Beta 3 or 4. As far as I can tell you still need the yaml file for multiple destinations? Not clear to me from the latest docs. I added the information into my yaml file per the docs but not sure what to do next? The sensors show in the developers tools. Not sure what to do next? Custom card?

Yes, I need yaml for multiple destination.
That is great news regarding the beta! :slight_smile:

In lovelace I was using a condition to change header between “Travel time to work” and “Travel time home” and then a custom card called “travel time card”.
Maybe there is something better now?
But this worked great for me and if you press the time it would open a new tab with map.

        conditions:
          - entity: person.me
            state: "not_home"
        card:
          type: 'custom:travel-time-card'
          show_header: true
          title: "Travel time to home"
          entities:
            - entity: sensor.google_travel_time
            - entity: sensor.waze_travel_time
1 Like

I finally understood the doc and used the template and input select sensor. This allows me to pick multiple destinations with a drop down. Set up an automation to automate the home assistant updater every 2 minutes as well as created a button to update now rather than the current updates of every 5 minutes.
I can post my configuration if interested.