Skip to content

Commit

Permalink
Merge pull request #2 from beauxq/soe-default-protocol-typing
Browse files Browse the repository at this point in the history
soe: change `FlagProtocol` to match `default` typing
  • Loading branch information
beauxq authored Jan 15, 2024
2 parents 9b38daa + 8697ba7 commit ae7604d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions worlds/soe/options.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from dataclasses import dataclass, fields
from typing import Any, cast, Dict, Iterator, List, Tuple, Protocol
from typing import Any, cast, Dict, Iterator, List, Literal, Tuple, Protocol, Union

from Options import AssembleOptions, Choice, DeathLink, DefaultOnToggle, PerGameCommonOptions, ProgressionBalancing, \
Range, Toggle
Expand All @@ -8,13 +8,12 @@
# typing boilerplate
class FlagsProtocol(Protocol):
value: int
default: int
flags: List[str]


class FlagProtocol(Protocol):
value: int
default: int
default: Union[int, Literal["random"]]
flag: str


Expand Down

0 comments on commit ae7604d

Please sign in to comment.