Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.11/site-packages/pydantic/_internal/_import_utils.py: 79%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

14 statements  

1from functools import cache 

2from typing import TYPE_CHECKING 

3 

4if TYPE_CHECKING: 

5 from pydantic import BaseModel 

6 from pydantic.fields import FieldInfo 

7 

8 

9@cache 

10def import_cached_base_model() -> type['BaseModel']: 

11 from pydantic import BaseModel 

12 

13 return BaseModel 

14 

15 

16@cache 

17def import_cached_field_info() -> type['FieldInfo']: 

18 from pydantic.fields import FieldInfo 

19 

20 return FieldInfo