forked from p15670423/monkey
Island: Annotate MachineID as a TypeAlias
See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
This commit is contained in:
parent
1deb03b6d7
commit
4662dd8bed
|
@ -1,5 +1,5 @@
|
|||
from ipaddress import IPv4Interface
|
||||
from typing import Optional, Sequence
|
||||
from typing import Optional, Sequence, TypeAlias
|
||||
|
||||
from pydantic import Field, PositiveInt, validator
|
||||
|
||||
|
@ -8,7 +8,7 @@ from common.base_models import MutableInfectionMonkeyBaseModel
|
|||
from common.transforms import make_immutable_sequence
|
||||
from common.types import HardwareID
|
||||
|
||||
MachineID = PositiveInt
|
||||
MachineID: TypeAlias = PositiveInt
|
||||
|
||||
|
||||
class Machine(MutableInfectionMonkeyBaseModel):
|
||||
|
|
Loading…
Reference in New Issue