Skip to content

Commit 4869a33

Browse files
committed
Enh: Metadata should contain entire config
1 parent de29b49 commit 4869a33

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

codeclash/games/abstract.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ def __init__(self, config: dict):
3131
self.scoreboard: list[tuple[int, str]] = []
3232
"""List of (round number, winner (player id))"""
3333
self.game_config: dict = config["game"]
34+
self.config: dict = config
3435
self.rounds: int = self.game_config.get("rounds", 1)
3536
self.round: int = 0
3637
self.game_id: str = f"{self.name}{time.strftime('%y%m%d%H%M%S')}"
@@ -86,7 +87,7 @@ def get_metadata(self) -> dict:
8687
return {
8788
"name": self.name,
8889
"scoreboard": self.scoreboard,
89-
"config": self.game_config,
90+
"config": self.config,
9091
"game_id": self.game_id,
9192
}
9293

0 commit comments

Comments
 (0)