Skip to content

Commit

Permalink
Remove fancy type annotations to work with Python 3.9
Browse files Browse the repository at this point in the history
  • Loading branch information
adinilfeld committed Mar 29, 2024
1 parent 248778e commit 1e8fc55
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class GetReply(BaseModel):
army: int # Number of troops owned by player

class GetReplyFlat(BaseModel):
board: List[int|str]
board: List
land: int # Number of tiles owned by player
army: int # Number of troops owned by player

Expand Down Expand Up @@ -71,7 +71,7 @@ def serialize_board(board:Board, playerid:int) -> List[List[Tuple[int, str, int]
return ret


def flatten(board: List[List[Tuple[int, str, int]]]) -> List[int|str|int]:
def flatten(board: List[List[Tuple[int, str, int]]]):
out = []
for row in board:
for square in row:
Expand Down

0 comments on commit 1e8fc55

Please sign in to comment.