Fix to top movers

Don't try processsing decks that don't have a score before the cut-off
date.
This commit is contained in:
Jack Jackson 2024-08-23 09:58:58 -07:00
parent f120336f1d
commit 5d2183bbf0

View File

@ -141,6 +141,7 @@ def top_movers(
- score_tracker[deck_id]["start_score"],
}
for deck_id in score_tracker
if "start_score" in score_tracker[deck_id]
]
return {
"positive": nlargest(number_of_movers, calculateds, key=lambda x: x["diff"]),