From da5d407a855d49f95ddb1eeccc930c97201cb724 Mon Sep 17 00:00:00 2001 From: Sander Roosendaal Date: Fri, 4 May 2018 11:18:33 +0200 Subject: [PATCH] fix bug zipfile no summary --- rowers/mailprocessing.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rowers/mailprocessing.py b/rowers/mailprocessing.py index 7cca55f7..f27ca372 100644 --- a/rowers/mailprocessing.py +++ b/rowers/mailprocessing.py @@ -118,6 +118,7 @@ def make_new_workout_from_email(rower, datafile, name, cntr=0,testing=False): return 0 summary = '' + # handle non-Painsled if fileformat != 'csv': @@ -147,10 +148,11 @@ def make_new_workout_from_email(rower, datafile, name, cntr=0,testing=False): except KeyError: pass + row.write_csv(datafilename, gzip=True) dosummary = (fileformat != 'fit' and 'speedcoach2' not in fileformat) dosummary = dosummary or summary == '' - + if name == '': name = 'Workout from Background Queue' @@ -158,6 +160,7 @@ def make_new_workout_from_email(rower, datafile, name, cntr=0,testing=False): datafilename, rower, workouttype=workouttype, dosummary=dosummary, + summary=summary, inboard=inboard, oarlength=oarlength, title=name,