pe-st / garmin-connect-export

Download a copy of your Garmin Connect data, including stats and GPX tracks.
MIT License
364 stars 75 forks source link

how to obtain the URL_GC_SEARCH #10

Closed TheKiteRunning closed 6 years ago

TheKiteRunning commented 6 years ago

I find the url links end with .com in the scrips are not applicable to Chinese users. Our website is end with cn

I have replaced all the urls and log in successfully, however, issue occurs when making request.

Finished authentication Making activity request ~~~~~~~~~~ https://connect.garmin.cn/proxy/activity-search-service-1.2/json/activities?start=0&limit=1 Traceback (most recent call last): File "gcexport3.py", line 283, in RESULT = http_req(URL_GC_SEARCH + urllib.parse.urlencode(SEARCH_PARAMS)) File "gcexport3.py", line 101, in http_req response = OPENER.open((request), data=post) File "D:\InstallFolder\Anaconda\lib\urllib\request.py", line 532, in open response = meth(req, response) File "D:\InstallFolder\Anaconda\lib\urllib\request.py", line 642, in http_response 'http', request, response, code, msg, hdrs) File "D:\InstallFolder\Anaconda\lib\urllib\request.py", line 570, in error return self._call_chain(args) File "D:\InstallFolder\Anaconda\lib\urllib\request.py", line 504, in _call_chain result = func(args) File "D:\InstallFolder\Anaconda\lib\urllib\request.py", line 650, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found

It seems the URL_GC_SEARCH is not applicable. Do you know how to get the right link for this issue.

Thanks

pe-st commented 6 years ago

Hello @TheKiteRunning

I see you're using the gcexport3.py script which is maintained in another repo: https://github.com/moderation/garmin-connect-export

Do you have the same issue when using gcexport.py (The Python 2.7 version of the script, the one that is maintained in my repo)?

TheKiteRunning commented 6 years ago

Hi, thank you for your help!

However, I have updated to python3, though I tried to install python 27 with the help of anocanda, there are still some problems with regard to gcexport.py.

Traceback (most recent call last): File "gcexport.py", line 23, in from sets import Set ImportError: cannot import name 'Set'