core: Google Maps Integration - Error during setup of component device_tracker

The problem

when i tryed config google maps share location i get error message:

Logger: homeassistant.setup
Source: components/device_tracker/legacy.py:885
First occurred: 13:44:42 (1 occurrences)
Last logged: 13:44:42

Error during setup of component device_tracker
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 235, in _async_setup_component
    result = await task
  File "/usr/src/homeassistant/homeassistant/components/device_tracker/__init__.py", line 50, in async_setup
    await async_setup_legacy_integration(hass, config)
  File "/usr/src/homeassistant/homeassistant/components/device_tracker/legacy.py", line 156, in async_setup_integration
    tracker = await get_tracker(hass, config)
  File "/usr/src/homeassistant/homeassistant/components/device_tracker/legacy.py", line 403, in get_tracker
    devices = await async_load_config(yaml_path, hass, consider_home)
  File "/usr/src/homeassistant/homeassistant/components/device_tracker/legacy.py", line 885, in async_load_config
    device.pop("vendor", None)
TypeError: pop expected at most 1 argument, got 2

What version of Home Assistant Core has the issue?

core-2022.4.7

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Google Maps

Link to integration documentation on our website

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

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 15 (1 by maintainers)

Most upvoted comments

This issue is still present in version 2022.9.2.

I was having this issue when I first set this up with 2022.12.0 today. I was using the Chrome get_cookies.txt extension. I then tried the Firefox Export_cookies addon. That worked. The difference I see is the Chrome version is adding a lot more cookies in the file. It looks like the google maps device tracker only wants the accounts.google.com and .google.com cookies. I then took my Chrome exported file and parsed it with grep and using sed added the Netscape Cookie header like this:

grep -e ‘^.google.com’ -e ‘^accounts.google.com’ google.com_cookies.txt | sed ‘1i # Netscape HTTP Cookie File\n’ > .google_maps_location_sharing.cookies.location_tracker_gmail_com

Now my google maps device tracker config works.