gabrielreid / polar-flow-export Goto Github PK
View Code? Open in Web Editor NEWCommand line tool for bulk exporting TCX files from Polar Flow
License: Apache License 2.0
Command line tool for bulk exporting TCX files from Polar Flow
License: Apache License 2.0
When trying to export session type of 'multisport' from Polar Flow the exporter throws error (400 bad request). That's due the download URL which is trying to download the plain tcx file. For some reason Flow provides only zipped version to be downloaded. So the issues lies on the line https://github.com/gabrielreid/polar-flow-export/blob/master/polarflowexport.py#L137 which has the 'false' in the URL.
How to get around? Read the response status code and try switching to zipped URL when 400. Or downloading all the sessions using zipped tcx files and unpacking them after download? The latter would be relatively easy to implement I guess. (Would try to fix a patch, but I'm limited with time at this moment)
PS. Huge thanks for this script - saved my day! Exporting the tcx files one by one (to be uploaded to TrainingPeaks) is pain in the ass.
I'm getting this error when trying the script:
INFO:PolarFlowExporter:Logging in user [email protected]
ERROR:PolarFlowExporter:Error fetching https://flow.polar.com/login: HTTP Error 400: Bad Request
Traceback (most recent call last):
File "polarflowexport.py", line 158, in
for tcx_file in exporter.get_tcx_files(from_date_str, to_date_str):
File "polarflowexport.py", line 114, in get_tcx_files
self._login()
File "polarflowexport.py", line 101, in _login
email=self._username, password=self._password))
File "polarflowexport.py", line 92, in _execute_request
raise Exception(e)
Exception: HTTP Error 400: Bad Request`
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.