Common: Move base_models.py to common

This commit is contained in:
Mike Salvatore 2022-08-22 11:19:15 -04:00
parent acc158db44
commit 3a94be8766
5 changed files with 6 additions and 3 deletions

View File

@ -4,3 +4,4 @@ Used for a common things between agent and island
from .di_container import DIContainer, UnresolvableDependencyError
from .operating_system import OperatingSystem
from . import types
from . import base_models

View File

@ -4,8 +4,9 @@ from uuid import UUID
from pydantic import Field
from common.base_models import MutableBaseModel
from . import MachineID
from .base_models import MutableBaseModel
class Agent(MutableBaseModel):

View File

@ -4,9 +4,9 @@ from typing import Optional, Sequence
from pydantic import Field, PositiveInt, validator
from common import OperatingSystem
from common.base_models import MutableBaseModel
from common.types import HardwareID
from .base_models import MutableBaseModel
from .transforms import make_immutable_sequence
MachineID = PositiveInt

View File

@ -2,8 +2,9 @@ from typing import Sequence, Tuple
from pydantic import Field, validator
from common.base_models import MutableBaseModel
from . import CommunicationType, MachineID
from .base_models import MutableBaseModel
from .transforms import make_immutable_nested_sequence
ConnectionsSequence = Sequence[Tuple[MachineID, Sequence[CommunicationType]]]