package_name_to_import_with.utils module#

Define helper utilities.

class CustomFloatEnum(value)[source]#

Bases: float, Enum

Inherit enum.Enum and modify behaviour of __str__.

pydantic model CustomPydanticBaseModel[source]#

Bases: BaseModel

Inherit pydantic.BaseModel and change behaviour to handle undefined attributes.

Show JSON schema
{
   "title": "CustomPydanticBaseModel",
   "description": "Inherit `pydantic.BaseModel` and change behaviour to handle undefined attributes.",
   "type": "object",
   "properties": {},
   "additionalProperties": false
}

Config:
  • extra: str = forbid

model_computed_fields: ClassVar[dict[str, ComputedFieldInfo]] = {}#

A dictionary of computed field names and their corresponding ComputedFieldInfo objects.

class CustomStrEnum(value)[source]#

Bases: str, Enum

Inherit enum.Enum and modify behaviour of __str__.