-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use enums for faction, leave reason in summary
This should avoid any future failures to update magic strings everywhere. I've put in custom (de)serialization annotations for pydantic so that the JSON version of the summary uses strings, not ints.
- Loading branch information
1 parent
3f5f26b
commit 04f51a6
Showing
4 changed files
with
47 additions
and
15 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
2 changes: 1 addition & 1 deletion
2
tests/replays/c6b4eb4e-4994-4e96-b098-3e1953a02033/CL44821-2024.02.03-18.48.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
{"build_number": 44821, "map_name": "Boneyard", "players": [{"nickname": "Pox", "nickname_discriminator": "8082", "uuid": "c6b4eb4e-4994-4e96-b098-3e1953a02033", "faction": "Infernals", "is_ai": false, "disconnect_time": 10.94140625, "leave_reason": "Unknown"}, {"nickname": "PeacefulBot", "nickname_discriminator": null, "uuid": null, "faction": "Vanguard", "is_ai": true, "disconnect_time": null, "leave_reason": "unknown"}], "spectators": [], "duration_seconds": 10.94140625, "is_1v1_ladder_game": false} | ||
{"build_number": 44821, "map_name": "Boneyard", "players": [{"nickname": "Pox", "nickname_discriminator": "8082", "uuid": "c6b4eb4e-4994-4e96-b098-3e1953a02033", "faction": "Infernals", "is_ai": false, "disconnect_time": 10.94140625, "leave_reason": "Unknown"}, {"nickname": "PeacefulBot", "nickname_discriminator": null, "uuid": null, "faction": "Vanguard", "is_ai": true, "disconnect_time": null, "leave_reason": "Unknown"}], "spectators": [], "duration_seconds": 10.94140625, "is_1v1_ladder_game": false} |
2 changes: 1 addition & 1 deletion
2
tests/replays/c6b4eb4e-4994-4e96-b098-3e1953a02033/CL44821-2024.02.13-22.25.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
{"build_number": 44821, "map_name": "JaggedMaw", "players": [{"nickname": "Pox", "nickname_discriminator": "8082", "uuid": "c6b4eb4e-4994-4e96-b098-3e1953a02033", "faction": "Infernals", "is_ai": false, "disconnect_time": 256.95703125, "leave_reason": "Unknown"}, {"nickname": "PeacefulBot", "nickname_discriminator": null, "uuid": null, "faction": "Vanguard", "is_ai": true, "disconnect_time": null, "leave_reason": "unknown"}], "spectators": [], "duration_seconds": 256.95703125, "is_1v1_ladder_game": false} | ||
{"build_number": 44821, "map_name": "JaggedMaw", "players": [{"nickname": "Pox", "nickname_discriminator": "8082", "uuid": "c6b4eb4e-4994-4e96-b098-3e1953a02033", "faction": "Infernals", "is_ai": false, "disconnect_time": 256.95703125, "leave_reason": "Unknown"}, {"nickname": "PeacefulBot", "nickname_discriminator": null, "uuid": null, "faction": "Vanguard", "is_ai": true, "disconnect_time": null, "leave_reason": "Unknown"}], "spectators": [], "duration_seconds": 256.95703125, "is_1v1_ladder_game": false} |