Standings history for current_rating-ranked tournaments - #308
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements #305:
/standings/historynow servescurrent_rating-ranked tournaments — the 501 guard is gone, completing therank_byfeature surface (#290).The sweep gains a second value-resolution mode alongside the peak ratchet, reusing all shared machinery (daily anchors + reorder-stamped buckets, roster visibility gating, team series, response shape):
_frozen_current_by_profile's precedence. Non-monotone by nature: declines chart as declines.old_rating— exact, games are the only mover) → else the latest pre-start observation → else earliest in-window observation carried back → else a flat line at livecurrent_rating(the recorder's self-seeding argument). Current-mode tournaments postdate the Per-tournament scoring config: rank_by (peak_rating | current_rating) #290 recorder, so observation coverage is complete from first poll — none of the peak mode's log-reconstruction (#357) is needed.max_ratingdesc (static tiebreak), name — the live table's current-mode order, so the final bucket provably matches/standings.Contract (additive):
StandingHistoryPoint.current_ratingandTeamStandingHistoryPoint.combined_current_elo— exactly one of the two rating fields per point is populated, matchingrank_by(the same split as the summary's rating cards);combined_peak_elobecomes nullable but is always populated in peak mode, so existing consumers see identical bytes. Consumers regenerate orval clients.Tests
594 passed. New: a decline charts as a decline with the reorder captured (the case peak mode can't express); final bucket equals the live
/standingscurrent-mode order; baselines hold before the first data point (entryold_ratingexact for a player with games, carried-back observation for a snapshot-only player); team series sums current with null peak fields. The five existing peak-mode whole-point assertions updated for the additive null keys — peak values and positions unchanged.Closes #305