Skip to content

Commit ff6b5cb

Browse files
committed
use __future__ import
1 parent bab862d commit ff6b5cb

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

python/pydantic_core/__init__.py

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
from __future__ import annotations
2+
13
import sys as _sys
24
from typing import Any as _Any
35

@@ -62,17 +64,17 @@
6264

6365
class ErrorDetails(_TypedDict):
6466
type: str
65-
loc: 'tuple[int | str, ...]'
67+
loc: tuple[int | str, ...]
6668
msg: str
6769
input: _Any
68-
ctx: _NotRequired['dict[str, str | int | float]']
70+
ctx: _NotRequired[dict[str, str | int | float]]
6971

7072

7173
class InitErrorDetails(_TypedDict):
72-
type: 'str | PydanticCustomError'
73-
loc: _NotRequired['tuple[int | str, ...]']
74+
type: str | PydanticCustomError
75+
loc: _NotRequired[tuple[int | str, ...]]
7476
input: _Any
75-
ctx: _NotRequired['dict[str, str | int | float]']
77+
ctx: _NotRequired[dict[str, str | int | float]]
7678

7779

7880
class ErrorTypeInfo(_TypedDict):
@@ -81,11 +83,11 @@ class ErrorTypeInfo(_TypedDict):
8183
example_message_python: str
8284
message_template_json: _NotRequired[str]
8385
example_message_json: _NotRequired[str]
84-
example_context: 'dict[str, str | int | float] | None'
86+
example_context: dict[str, str | int | float] | None
8587

8688

8789
class MultiHostHost(_TypedDict):
88-
username: 'str | None'
89-
password: 'str | None'
90-
host: 'str | None'
91-
port: 'int | None'
90+
username: str | None
91+
password: str | None
92+
host: str | None
93+
port: int | None

0 commit comments

Comments
 (0)