Private
Public Access
1
0

Merge branch 'release/v9.90'

This commit is contained in:
Sander Roosendaal
2019-05-15 22:00:11 +02:00
3 changed files with 15 additions and 14 deletions
-5
View File
@@ -1350,7 +1350,6 @@ def new_workout_from_file(r, f2,
# handle non-Painsled by converting it to painsled compatible CSV
if (fileformat != 'csv'):
try:
f2, summary, oarlength, inboard, fileformat = handle_nonpainsled(
f2,
fileformat,
@@ -1359,10 +1358,6 @@ def new_workout_from_file(r, f2,
if not f2:
message = 'Something went wrong'
return (0, message, '')
except Exception as e:
errorstring = str(sys.exc_info()[0])
message = 'Something went wrong: ' + e.message
return (0, message, '')
dosummary = (fileformat != 'fit' and 'speedcoach2' not in fileformat)
dosummary = dosummary or summary == ''
+6
View File
@@ -316,7 +316,10 @@ def get_workout(user,stravaid):
coords = get_strava_stream(r,'latlng',stravaid)
power = get_strava_stream(r,'power',stravaid)
if t is not None:
nr_rows = len(t)
else:
return(0,"Error: Time data wasnt found")
if nr_rows == 0:
return (0,"Error: Time data had zero length")
@@ -701,7 +704,10 @@ def handle_strava_import_stroke_data(title,
coords = get_strava_stream(r,'latlng',stravaid)
power = get_strava_stream(r,'power',stravaid)
if t is not None:
nr_rows = len(t)
else:
return 0
if nr_rows == 0:
return 0
Binary file not shown.