Scarygami / location-history-json-converter

Convert the Location History JSON File from Google Takeout into a useable format
Apache License 2.0
468 stars 117 forks source link

Script returning "SyntaxError: invalid syntax" #23

Closed jbsjbs closed 4 years ago

jbsjbs commented 5 years ago

Downloaded Location history JSON today (2019-04-17). Installed latest python and ran script. No matter what parameters I use I'm getting this error:

https://i.imgur.com/bmLDVrQ.png

I initially tried it with the following switches:

-o locations.csv -f csv -c

but one by one I've eliminated those to see whether my switches were the problem. Is this related to a change in the JSON format or am I doing something wrong? Thanks!

RodrigoCMoraes commented 5 years ago

I think it is fixed, at least this script works like a charm for me. I execute with:

python location_history_json_converter.py Location\ History.json -f csv -s 2019-01-01 -c

My environment:

At image that you share @jbsjbs I can't see your python interpreter, just your json file as interpreter, maybe you can check that.

Scarygami commented 4 years ago

From the error message it seems that you have actually downloaded the GitHub-Website (HTML) instead of the actual python script, also because the filesize of your location_history_json_converter.py in the screenshot is far too big.

Make sure to download the raw python script and try again.