mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-28 06:23:07 +00:00
chore(deps): require pydantic>=2.12.0 so TypedDict extra_items keys survive validation
This commit is contained in:
parent
641c167fd2
commit
351d15352b
4 changed files with 19 additions and 6 deletions
|
|
@ -26,8 +26,7 @@ dependencies = [
|
|||
"aiohttp>=3.14.2,<4.0",
|
||||
"anyio>=4.14.0,<5.0",
|
||||
"async-timeout>=4.0.3,<6.0; python_version < '3.11'",
|
||||
"pydantic>=2.11.0,<3.0.0; python_version < '3.14'",
|
||||
"pydantic>=2.12.0,<3.0.0; python_version >= '3.14'",
|
||||
"pydantic>=2.12.0,<3.0.0",
|
||||
"pydantic-settings>=2.14.1,<3.0",
|
||||
"jsonschema>=4.0.0,<5.0",
|
||||
"typing-extensions>=4.13.0,<5.0",
|
||||
|
|
|
|||
|
|
@ -31,8 +31,7 @@ dependencies = [
|
|||
"aiohttp>=3.14.2,<4.0",
|
||||
"anyio>=4.14.0,<5.0",
|
||||
"async-timeout>=4.0.3,<6.0; python_version < '3.11'",
|
||||
"pydantic>=2.11.0,<3.0.0; python_version < '3.14'",
|
||||
"pydantic>=2.12.0,<3.0.0; python_version >= '3.14'",
|
||||
"pydantic>=2.12.0,<3.0.0",
|
||||
"pydantic-settings>=2.14.1,<3.0",
|
||||
"jsonschema>=4.0.0,<5.0",
|
||||
"boto3>=1.43.1,<2.0",
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@ AIOHTTP_POOL_POISONING_RELEASES: Final = ("3.14.0", "3.14.1")
|
|||
AIOHTTP_POOL_POISONING_SOURCE: Final = "aio-libs/aiohttp#12953, fixed in aiohttp 3.14.2"
|
||||
ANYIO_STRANDED_LOCK_WAITER_FIX: Final = Version("4.14.0")
|
||||
ANYIO_STRANDED_LOCK_WAITER_SOURCE: Final = "agronholm/anyio#1145, fixed in anyio 4.14.0 released 2026-06-15"
|
||||
PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SUPPORT: Final = Version("2.12.0")
|
||||
PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SOURCE: Final = "TypeAdapter drops PEP 728 extra_items keys on pydantic 2.11.7, keeps them on 2.12.0 (probed 2026-10-19)"
|
||||
CLI_RUNTIME_DEPENDENCIES: Final = frozenset({"rich", "pyyaml", "requests"})
|
||||
PROXY_SERVER_ONLY_DEPENDENCIES: Final = frozenset(
|
||||
{
|
||||
|
|
@ -109,3 +111,17 @@ def test_declared_anyio_floor_is_at_or_above_stranded_lock_waiter_fix() -> None:
|
|||
specifier.operator == ">=" and Version(specifier.version) >= ANYIO_STRANDED_LOCK_WAITER_FIX
|
||||
for specifier in declared[0].specifier
|
||||
), ANYIO_STRANDED_LOCK_WAITER_SOURCE
|
||||
|
||||
|
||||
def test_declared_pydantic_floor_keeps_typed_dict_extra_items() -> None:
|
||||
declared: Final = tuple(
|
||||
Requirement(requirement)
|
||||
for requirement in PYPROJECT["project"]["dependencies"]
|
||||
if canonicalize_name(Requirement(requirement).name) == "pydantic"
|
||||
)
|
||||
assert len(declared) == 1, PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SOURCE
|
||||
assert declared[0].marker is None, PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SOURCE
|
||||
assert any(
|
||||
specifier.operator == ">=" and Version(specifier.version) >= PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SUPPORT
|
||||
for specifier in declared[0].specifier
|
||||
), PYDANTIC_TYPED_DICT_EXTRA_ITEMS_SOURCE
|
||||
|
|
|
|||
3
uv.lock
generated
3
uv.lock
generated
|
|
@ -4832,8 +4832,7 @@ requires-dist = [
|
|||
{ name = "prometheus-client", marker = "extra == 'proxy-runtime'", specifier = ">=0.20.0,<1.0" },
|
||||
{ name = "psycopg", marker = "extra == 'extra-proxy'", specifier = ">=3.2,<4.0" },
|
||||
{ name = "psycopg-binary", marker = "extra == 'extra-proxy'", specifier = ">=3.2,<4.0" },
|
||||
{ name = "pydantic", marker = "python_full_version < '3.14'", specifier = ">=2.11.0,<3.0.0" },
|
||||
{ name = "pydantic", marker = "python_full_version >= '3.14'", specifier = ">=2.12.0,<3.0.0" },
|
||||
{ name = "pydantic", specifier = ">=2.12.0,<3.0.0" },
|
||||
{ name = "pydantic", marker = "extra == 'mcp'", specifier = ">=2.12.0,<3" },
|
||||
{ name = "pydantic", marker = "extra == 'proxy'", specifier = ">=2.12.0,<3" },
|
||||
{ name = "pydantic-settings", specifier = ">=2.14.1,<3.0" },
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue