imports no stroke data by creating synthetic workout
This commit is contained in:
@@ -56,7 +56,7 @@ def add(x, y):
|
||||
@app.task
|
||||
def handle_c2_import_stroke_data(c2token,
|
||||
c2id,workoutid,
|
||||
startdatetime,
|
||||
starttimeunix,
|
||||
csvfilename,debug=True):
|
||||
authorizationstring = str('Bearer ' + c2token)
|
||||
headers = {'Authorization': authorizationstring,
|
||||
@@ -66,7 +66,6 @@ def handle_c2_import_stroke_data(c2token,
|
||||
s = requests.get(url,headers=headers)
|
||||
if s.status_code == 200:
|
||||
strokedata = pd.DataFrame.from_dict(s.json()['data'])
|
||||
starttimeunix = arrow.get(startdatetime).timestamp
|
||||
result = add_c2_stroke_data_db(
|
||||
strokedata,workoutid,starttimeunix,
|
||||
csvfilename,debug=debug,
|
||||
|
||||
Reference in New Issue
Block a user