- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for is_pv1_scalar_field (0.41 sec)
-
tests/test_compat.py
from fastapi._compat import is_pv1_scalar_field field_info = FieldInfo() field = ModelField( name="foo", field_info=field_info, type_=Union[str, List[int]], class_validators={}, model_config=BaseConfig, ) assert not is_pv1_scalar_field(field) @needs_pydanticv2 def test_get_model_config():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Sep 11 07:45:30 UTC 2024 - 3.5K bytes - Viewed (0) -
fastapi/_compat.py
if "description" in m_schema: m_schema["description"] = m_schema["description"].split("\f")[0] definitions[model_name] = m_schema return definitions def is_pv1_scalar_field(field: ModelField) -> bool: from fastapi import params field_info = field.field_info if not ( field.shape == SHAPE_SINGLETON # type: ignore[attr-defined]
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Oct 12 09:36:32 UTC 2024 - 23.4K bytes - Viewed (0)