anydi 0.26.6__py3-none-any.whl → 0.26.7__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- anydi/_utils.py +9 -7
- {anydi-0.26.6.dist-info → anydi-0.26.7.dist-info}/METADATA +1 -1
- {anydi-0.26.6.dist-info → anydi-0.26.7.dist-info}/RECORD +6 -6
- {anydi-0.26.6.dist-info → anydi-0.26.7.dist-info}/LICENSE +0 -0
- {anydi-0.26.6.dist-info → anydi-0.26.7.dist-info}/WHEEL +0 -0
- {anydi-0.26.6.dist-info → anydi-0.26.7.dist-info}/entry_points.txt +0 -0
anydi/_utils.py
CHANGED
|
@@ -16,6 +16,10 @@ except ImportError:
|
|
|
16
16
|
anyio = None # type: ignore[assignment]
|
|
17
17
|
|
|
18
18
|
|
|
19
|
+
T = TypeVar("T")
|
|
20
|
+
P = ParamSpec("P")
|
|
21
|
+
|
|
22
|
+
|
|
19
23
|
def evaluate_forwardref(type_: ForwardRef, globalns: Any, localns: Any) -> Any:
|
|
20
24
|
if sys.version_info < (3, 9):
|
|
21
25
|
return type_._evaluate(globalns, localns) # noqa
|
|
@@ -26,10 +30,6 @@ def evaluate_forwardref(type_: ForwardRef, globalns: Any, localns: Any) -> Any:
|
|
|
26
30
|
return type_._evaluate(globalns, localns, frozenset()) # noqa
|
|
27
31
|
|
|
28
32
|
|
|
29
|
-
T = TypeVar("T")
|
|
30
|
-
P = ParamSpec("P")
|
|
31
|
-
|
|
32
|
-
|
|
33
33
|
def get_full_qualname(obj: Any) -> str:
|
|
34
34
|
"""Get the fully qualified name of an object."""
|
|
35
35
|
qualname = getattr(obj, "__qualname__", None)
|
|
@@ -69,10 +69,12 @@ def get_typed_annotation(
|
|
|
69
69
|
) -> Any:
|
|
70
70
|
"""Get the typed annotation of a parameter."""
|
|
71
71
|
if isinstance(annotation, str):
|
|
72
|
-
if sys.version_info
|
|
73
|
-
annotation = ForwardRef(annotation)
|
|
74
|
-
else:
|
|
72
|
+
if sys.version_info >= (3, 10, 2):
|
|
75
73
|
annotation = ForwardRef(annotation, module=module, is_class=is_class)
|
|
74
|
+
elif sys.version_info >= (3, 10, 0):
|
|
75
|
+
annotation = ForwardRef(annotation, module=module)
|
|
76
|
+
else:
|
|
77
|
+
annotation = ForwardRef(annotation)
|
|
76
78
|
annotation = evaluate_forwardref(annotation, globalns, {})
|
|
77
79
|
return annotation
|
|
78
80
|
|
|
@@ -5,7 +5,7 @@ anydi/_logger.py,sha256=UpubJUnW83kffFxkhUlObm2DmZX1Pjqoz9YFKS-JOPg,52
|
|
|
5
5
|
anydi/_module.py,sha256=E1TfLud_Af-MPB83PxIzHVA1jlDW2FGaRP_il1a6y3Y,3675
|
|
6
6
|
anydi/_scanner.py,sha256=cyEk-K2Q8ssZStq8GrxMeEcCuAZMw-RXrjlgWEevKCs,6667
|
|
7
7
|
anydi/_types.py,sha256=i8xFxz8pmFj7SGqwOwae_P9VtiRie6DVLwfaLibLwhc,3653
|
|
8
|
-
anydi/_utils.py,sha256=
|
|
8
|
+
anydi/_utils.py,sha256=TzUZRTNaXu78Uzv9NCNLSM5s9TgEIiXtXgr1HhsfHac,4017
|
|
9
9
|
anydi/ext/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
10
|
anydi/ext/django/__init__.py,sha256=QI1IABCVgSDTUoh7M9WMECKXwB3xvh04HfQ9TOWw1Mk,223
|
|
11
11
|
anydi/ext/django/_container.py,sha256=cxVoYQG16WP0S_Yv4TnLwuaaT7NVEOhLWO-YdALJUb4,418
|
|
@@ -21,8 +21,8 @@ anydi/ext/pytest_plugin.py,sha256=3OWphc4nEzla46_8KR7LXtwGns5eol_YlUWfTf4Cr2Q,39
|
|
|
21
21
|
anydi/ext/starlette/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
22
22
|
anydi/ext/starlette/middleware.py,sha256=Ni0BQaPjs_Ha6zcLZYYJ3-XkslTCnL9aCSa06rnRDMI,1139
|
|
23
23
|
anydi/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
24
|
-
anydi-0.26.
|
|
25
|
-
anydi-0.26.
|
|
26
|
-
anydi-0.26.
|
|
27
|
-
anydi-0.26.
|
|
28
|
-
anydi-0.26.
|
|
24
|
+
anydi-0.26.7.dist-info/LICENSE,sha256=V6rU8a8fv6o2jQ-7ODHs0XfDFimot8Q6Km6CylRIDTo,1069
|
|
25
|
+
anydi-0.26.7.dist-info/METADATA,sha256=_z0STd3mxaFj3pfj4aEcX2C9wER-eVgC_wz9Z-DbkbA,5110
|
|
26
|
+
anydi-0.26.7.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
27
|
+
anydi-0.26.7.dist-info/entry_points.txt,sha256=GmQblwzxFg42zva1HyBYJJ7TvrTIcSAGBHmyi3bvsi4,42
|
|
28
|
+
anydi-0.26.7.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|