This commit is contained in:
2025-03-21 16:32:24 -03:00
parent 9d7ff8abf1
commit 59635bf5d2

View File

@@ -3,6 +3,7 @@ from abc import ABC, abstractmethod
from datetime import datetime
from ipaddress import IPv4Address
from typing import Any, Type, TypedDict
from uuid import UUID
from aws_lambda_powertools import Logger
from boto3.dynamodb.types import TypeDeserializer, TypeSerializer
@@ -24,6 +25,8 @@ def _serialize_python_type(value: Any) -> str | dict | list:
match value:
case datetime():
return value.isoformat()
case UUID():
return str(value)
case IPv4Address():
return str(value)
case list() | tuple():