|
@ -47,6 +47,7 @@ sequence_types = tuple(sequence_annotation_to_type.keys()) |
|
|
|
|
|
|
|
|
if PYDANTIC_V2: |
|
|
if PYDANTIC_V2: |
|
|
from pydantic import PydanticSchemaGenerationError as PydanticSchemaGenerationError |
|
|
from pydantic import PydanticSchemaGenerationError as PydanticSchemaGenerationError |
|
|
|
|
|
from pydantic.errors import PydanticUndefinedAnnotation as PydanticUndefinedAnnotation |
|
|
from pydantic import TypeAdapter |
|
|
from pydantic import TypeAdapter |
|
|
from pydantic import ValidationError as ValidationError |
|
|
from pydantic import ValidationError as ValidationError |
|
|
from pydantic._internal._schema_generation_shared import ( # type: ignore[attr-defined] |
|
|
from pydantic._internal._schema_generation_shared import ( # type: ignore[attr-defined] |
|
@ -358,6 +359,9 @@ else: |
|
|
class PydanticSchemaGenerationError(Exception): # type: ignore[no-redef] |
|
|
class PydanticSchemaGenerationError(Exception): # type: ignore[no-redef] |
|
|
pass |
|
|
pass |
|
|
|
|
|
|
|
|
|
|
|
class PydanticUndefinedAnnotation(Exception): # type: ignore[no-redef] |
|
|
|
|
|
pass |
|
|
|
|
|
|
|
|
def with_info_plain_validator_function( # type: ignore[misc] |
|
|
def with_info_plain_validator_function( # type: ignore[misc] |
|
|
function: Callable[..., Any], |
|
|
function: Callable[..., Any], |
|
|
*, |
|
|
*, |
|
|