Merge branch 'hotfix/v2.98'
This commit is contained in:
@@ -250,7 +250,12 @@ def createstravaworkoutdata(w):
|
|||||||
|
|
||||||
row = rowingdata(filename)
|
row = rowingdata(filename)
|
||||||
tcxfilename = filename[:-4]+'.tcx'
|
tcxfilename = filename[:-4]+'.tcx'
|
||||||
row.exporttotcx(tcxfilename,notes=w.notes+'\n from '+w.workoutsource+' via rowsandall.com')
|
try:
|
||||||
|
newnotes = w.notes+'\n from '+w.workoutsource+' via rowsandall.com'
|
||||||
|
except TypeError:
|
||||||
|
newnotes = 'from '+w.workoutsource+' via rowsandall.com'
|
||||||
|
|
||||||
|
row.exporttotcx(tcxfilename,notes=newnotes)
|
||||||
gzfilename = tcxfilename+'.gz'
|
gzfilename = tcxfilename+'.gz'
|
||||||
with file(tcxfilename,'rb') as inF:
|
with file(tcxfilename,'rb') as inF:
|
||||||
s = inF.read()
|
s = inF.read()
|
||||||
|
|||||||
@@ -218,16 +218,18 @@ def getidfromresponse(response):
|
|||||||
|
|
||||||
def createtpworkoutdata(w):
|
def createtpworkoutdata(w):
|
||||||
filename = w.csvfilename
|
filename = w.csvfilename
|
||||||
|
row = rowingdata(filename)
|
||||||
|
tcxfilename = filename[:-4]+'.tcx'
|
||||||
try:
|
try:
|
||||||
row = rowingdata(filename)
|
newnotes = w.notes+'\n from '+w.workoutsource+' via rowsandall.com'
|
||||||
tcxfilename = filename[:-4]+'.tcx'
|
except TypeError:
|
||||||
row.exporttotcx(tcxfilename,notes=w.notes+'\n from '+w.workoutsource+' via rowsandall.com')
|
newnotes = 'from '+w.workoutsource+' via rowsandall.com'
|
||||||
return tcxfilename
|
|
||||||
except:
|
row.exporttotcx(tcxfilename,notes=newnotes)
|
||||||
tcxfilename = 0
|
|
||||||
|
|
||||||
return tcxfilename
|
return tcxfilename
|
||||||
|
|
||||||
|
|
||||||
def tp_check(access_token):
|
def tp_check(access_token):
|
||||||
headers = {
|
headers = {
|
||||||
"Content-Type": "application/json",
|
"Content-Type": "application/json",
|
||||||
|
|||||||
Reference in New Issue
Block a user