Closed kuaka closed 3 years ago
found that this was because in "converting" the comp to internal the tracks were deleted. This is the right thing to do (normally they are fake tracks, but I had uploaded previously). The issue now becomes that it is possible to try to score a task with no tracks which causes the above error
Ok, I guess this error will generate even in internal comps with no tracks and using difficulty points. I'm convinced the formula is wrong, anyway the easy solution is to avoid scoring empty tasks, that makes sense anyway.
commit https://github.com/FAI-CIVL/FAI-Airscore/commit/ea57632b330734d0cdb46eeca01f57900af28d6e should avoid the error. Do you confirm?
yes. fixed. thanks.
airscore_prod | File "/app/airscore/core/formulas/gap2016.py", line 152, in calculate_results airscore_prod | day_quality(task) airscore_prod | File "/app/airscore/core/formulas/libs/gap.py", line 205, in day_quality airscore_prod | task.dist_validity = distance_validity(task) airscore_prod | File "/app/airscore/core/formulas/libs/gap.py", line 123, in distance_validity airscore_prod | BestDistOverNom = task.max_distance - nomdist # best distance flown ove minimum dist. airscore_prod | File "/app/airscore/core/task.py", line 416, in max_distance airscore_prod | return max(max(p.distance for p in self.valid_results), self.formula.min_dist) airscore_prod | ValueError: max() arg is an empty sequence