Private
Public Access
1
0

Merge branch 'release/v23.6.11'

This commit is contained in:
2025-10-15 20:28:20 +02:00
5 changed files with 21 additions and 5 deletions
+3
View File
@@ -189,7 +189,10 @@ def sort_coordinates_ccw(coordinates):
def crewnerdcourse(doc): def crewnerdcourse(doc):
courses = [] courses = []
for course in doc: for course in doc:
try:
name = course.findall('.//opengis:name', ns)[0].text name = course.findall('.//opengis:name', ns)[0].text
except IndexError:
name = 'No name'
try: try:
description = course.findall('.//opengis:description', ns)[0].text description = course.findall('.//opengis:description', ns)[0].text
except IndexError: except IndexError:
+5
View File
@@ -2456,6 +2456,11 @@ def dataplep(rowdatadf, id=0, inboard=0.88, forceunit='lbs', bands=True, barchar
) )
if 'Check' in df.columns:
# rename column to check_factor
df = df.rename({'Check': 'check_factor'})
if 'check_factor' not in df.columns: if 'check_factor' not in df.columns:
data = data.with_columns( data = data.with_columns(
check_factor = pl.lit(0.0), check_factor = pl.lit(0.0),
+8
View File
@@ -1283,7 +1283,12 @@ def handle_check_race_course(self,
dologging(logfile2,"Did not find file "+f1) dologging(logfile2,"Did not find file "+f1)
return 0 return 0
try:
row.extend_data() row.extend_data()
except KeyError: # pragma: no cover
dologging(logfile,"Could not extend data")
dologging(logfile2,"Could not extend data")
return 0
# row.df.interpolate(inplace=True) # row.df.interpolate(inplace=True)
@@ -1315,8 +1320,11 @@ def handle_check_race_course(self,
).values ).values
rowdata = rowdata.select_dtypes(['number']) rowdata = rowdata.select_dtypes(['number'])
try:
rowdata = rowdata.resample('100ms', on='dt').mean() rowdata = rowdata.resample('100ms', on='dt').mean()
rowdata = rowdata.interpolate() rowdata = rowdata.interpolate()
except TypeError: # pragma: no cover
pass
course = GeoCourse.objects.get(id=courseid) course = GeoCourse.objects.get(id=courseid)
polygons = course.polygons.all() polygons = course.polygons.all()
Binary file not shown.
+1 -1
View File
@@ -644,7 +644,7 @@ def strokedata_fit(request):
dologging('apilog.log','FIT API endpoint') dologging('apilog.log','FIT API endpoint')
dologging('apilog.log',e) dologging('apilog.log',e)
_ = myqueue(queuehigh, handle_sendemail_unrecognized, fit_filename, "fit parser") _ = myqueue(queuehigh, handle_sendemail_unrecognized, fit_filename, "fit parser")
return HttpResponse(status=500) return JSONResponse({"error": "the uploaded file is corrupted or invalid and cannot be processed"}, status=422)