costastf / locationsharinglib

A library to retrieve coordinates from an google account that has been shared locations of other accounts.
MIT License
170 stars 29 forks source link

Fix problem with missing location #40

Closed Yevrashka closed 6 years ago

Yevrashka commented 6 years ago

Could you please add this fix to the lib? It helps many people using your lib in HomeAssistant. Thanks! https://github.com/jedi7/locationsharinglib/commit/e0cb8e6afd2269c7cadbdcc77b33b0a8ada7584a

costastf commented 6 years ago

I have added a version of this fix on the latest library. Could you please try v3.0.3 and let me know if that does not work for you?

Yevrashka commented 6 years ago

Thanks a lot! v.3.0.3 was added to the prerelease beta of Home Assistant yesterday, so I will check it after release. Hope it will work properly.

costastf commented 6 years ago

you can just bump the version manually on the component to the latest one and try it out without updating HA. Actually please use 3.0.5 since I fixed something else there too.

Yevrashka commented 6 years ago

All the libs are on the host system but I have no access to the host system from the hassio docker container, so have to wait until release..

costastf commented 6 years ago

@Yevrashka Any updates on this?

Yevrashka commented 6 years ago

Still doesn't work for me on v.3.0.3 Here is a part of the log that shows the error in HA, don't know if it will help somehow ERROR (MainThread) [homeassistant.components.device_tracker] Error setting up platform google_maps Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/homeassistant/components/device_tracker/__init__.py", line 184, in async_setup_platform disc_info) File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run result = self.fn(*self.args, **self.kwargs) File "/usr/local/lib/python3.6/site-packages/homeassistant/components/device_tracker/google_maps.py", line 46, in setup_scanner scanner = GoogleMapsScanner(hass, config, see) File "/usr/local/lib/python3.6/site-packages/homeassistant/components/device_tracker/google_maps.py", line 66, in __init__ self._update_info() File "/usr/local/lib/python3.6/site-packages/homeassistant/components/device_tracker/google_maps.py", line 78, in _update_info for person in self.service.get_all_people(): File "/usr/local/lib/python3.6/site-packages/locationsharinglib/locationsharinglib.py", line 459, in get_all_people people = self.get_shared_people() + [self.get_authenticated_person()] File "/usr/local/lib/python3.6/site-packages/locationsharinglib/locationsharinglib.py", line 421, in get_shared_people for info in output[0]: TypeError: 'NoneType' object is not iterable

costastf commented 6 years ago

Please try v3.0.6. The problem should be fixed in that version.

Yevrashka commented 6 years ago

v.3.0.6 doesn't help, got the same errors as here https://github.com/costastf/locationsharinglib/issues/42