diff --git a/rowers/interactiveplots.py b/rowers/interactiveplots.py index 6b996747..6953500a 100644 --- a/rowers/interactiveplots.py +++ b/rowers/interactiveplots.py @@ -1555,7 +1555,7 @@ def fitnessfit_chart(workouts,user,workoutmode='water',startdate=None, except: pass - + if len(data)>1: df = pd.concat(data,axis=0) @@ -1719,7 +1719,14 @@ def fitnessfit_chart(workouts,user,workoutmode='water',startdate=None, try: script,div = components(plot) except: - return '','Something went wrong withthe chart' + df.dropna(inplace=True,axis=0,how='any') + return ( + '', + 'Something went wrong withthe chart ({nrworkouts} workouts, {nrdata} datapoints)'.format( + nrworkouts = workouts.count(), + nrdata = len(df), + ) + ) return [script,div]