Add ranking metric expansion

This commit is contained in:
devRaGonSa
2026-06-09 07:32:29 +02:00
parent f74ac17f48
commit 12a215d11a
13 changed files with 869 additions and 94 deletions

View File

@@ -205,7 +205,9 @@ def _normalize_server_key(server_key: str | None) -> str:
def _normalize_metric(metric: str) -> str:
normalized = str(metric or "kills").strip().lower()
if normalized != "kills":
raise ValueError("Only metric 'kills' is supported for annual ranking endpoints.")
raise ValueError(
f"Metric '{normalized}' is not supported for annual ranking snapshots."
)
return normalized