Private
Public Access
1
0

running tests, fixed issues

This commit is contained in:
2024-03-27 07:14:34 +01:00
parent d00d41c09f
commit cccb0be36c
3 changed files with 8 additions and 4 deletions

View File

@@ -4175,10 +4175,16 @@ def interactive_multiple_compare_chart(ids, xparam, yparam, plottype='line',
compute=compute,
workstrokesonly=workstrokesonly, for_chart=True)
# check if dataframe not empty
if datadf.empty: # pragma: no cover
return ['<p>No non-zero data in selection</p>', '']
datadf['workoutid'] = datadf['workoutid'].astype(int)
datadf.dropna(axis=1, how='all', inplace=True)
datadf.dropna(axis=0, how='all', inplace=True)
nrworkouts = len(ids)
try:
@@ -4187,11 +4193,11 @@ def interactive_multiple_compare_chart(ids, xparam, yparam, plottype='line',
try:
tseconds = datadf.loc[:, xparam]
except:
return ['', '<p>A chart data error occurred</p>', '', 'A chart data error occurred']
return ['<p>A chart data error occurred</p>', '']
# check if dataframe not empty
if datadf.empty: # pragma: no cover
return ['', '<p>No non-zero data in selection</p>', '', 'No non-zero data in selection']
return ['<p>No non-zero data in selection</p>', '']
if (xparam == 'time'):