Chore: Refactored import of BaseModel from pydantic
This commit is contained in:
parent
d3741a63ed
commit
b62bf1bcca
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -3,12 +3,12 @@ import uuid
|
|||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
from .cost_centre import CostCentreLink
|
from .cost_centre import CostCentreLink
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
from .account import AccountLink
|
from .account import AccountLink
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
from pydantic.main import BaseModel
|
from pydantic import BaseModel
|
||||||
|
|
||||||
|
|
||||||
class Message(BaseModel):
|
class Message(BaseModel):
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
from brewman.schemas import to_camel
|
from brewman.schemas import to_camel
|
||||||
from pydantic import ConfigDict
|
from pydantic import BaseModel, ConfigDict
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
|
|
||||||
class PermissionItem(BaseModel):
|
class PermissionItem(BaseModel):
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
from .product import ProductLink
|
from .product import ProductLink
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -3,12 +3,12 @@ import uuid
|
|||||||
from datetime import date, datetime
|
from datetime import date, datetime
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
from .account import AccountLink
|
from .account import AccountLink
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
from brewman.schemas import to_camel
|
from brewman.schemas import to_camel
|
||||||
from pydantic import ConfigDict, Field
|
from pydantic import BaseModel, ConfigDict, Field
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from .permission import PermissionItem
|
from .permission import PermissionItem
|
||||||
|
|
||||||
|
@ -4,12 +4,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@ from datetime import date, datetime
|
|||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
|
|
||||||
|
@ -3,13 +3,13 @@ import uuid
|
|||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
from pydantic import (
|
from pydantic import (
|
||||||
|
BaseModel,
|
||||||
ConfigDict,
|
ConfigDict,
|
||||||
Field,
|
Field,
|
||||||
FieldSerializationInfo,
|
FieldSerializationInfo,
|
||||||
field_serializer,
|
field_serializer,
|
||||||
field_validator,
|
field_validator,
|
||||||
)
|
)
|
||||||
from pydantic.main import BaseModel
|
|
||||||
|
|
||||||
from . import to_camel
|
from . import to_camel
|
||||||
from .role import RoleItem
|
from .role import RoleItem
|
||||||
|
Loading…
Reference in New Issue
Block a user