Find the highest round number that exists for a player.
(log_folder: Path, player_name: str)
| 67 | |
| 68 | |
| 69 | def find_max_round_for_player(log_folder: Path, player_name: str) -> int: |
| 70 | """Find the highest round number that exists for a player.""" |
| 71 | player_dir = log_folder / "players" / player_name |
| 72 | changes_files = list(player_dir.glob("changes_r*.json")) |
| 73 | rounds = [int(f.stem.split("_r")[1]) for f in changes_files] |
| 74 | return max(rounds) if rounds else 0 |
| 75 | |
| 76 | |
| 77 | def _compute_code_sim_difflib(diff1: PatchSet, diff2: PatchSet) -> float: |
nothing calls this directly
no outgoing calls
no test coverage detected