Skip to content

Commit

Permalink
fix serialization bug + add corresponding unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
ritikmishra committed Aug 24, 2021
1 parent 3a678dc commit b4a86c3
Show file tree
Hide file tree
Showing 3 changed files with 369,734 additions and 10 deletions.
12 changes: 11 additions & 1 deletion anacreonlib/types/response_datatypes.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,16 @@ class World(AnacreonObjectWithId):

battle_plan: Optional[BattlePlanDetails]

#: If the world is going to change tech levels soon, the value of this
#: field is the target tech level
target_tech_level: Optional[TechLevel]

#: If the population is going to change, the value of this field is
#: what the planet is heading towards
#:
#: Unit is millions of people
target_population: Optional[int]

region: NebulaType = NebulaType.CLEAR_SPACE

@functools.cached_property
Expand Down Expand Up @@ -315,7 +325,7 @@ class OwnedWorld(World):
base_consumption: List[Union[int, None]]
news: Optional[List[News]]

trade_route_max: int
trade_route_max: Optional[int]

rev_index: RevIndex

Expand Down
Loading

0 comments on commit b4a86c3

Please sign in to comment.