From 3a54f5fc1c746ee437a959b7f893997cfaf1c0c4 Mon Sep 17 00:00:00 2001 From: Artur Shiriev Date: Wed, 7 Oct 2026 19:11:15 +0300 Subject: [PATCH] fix: annotate context managers with Generator for ty 0.0.85 --- tests/test_inject.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_inject.py b/tests/test_inject.py index 2f2f014..b2488b5 100644 --- a/tests/test_inject.py +++ b/tests/test_inject.py @@ -1,3 +1,4 @@ +import collections.abc import contextlib import contextvars import typing @@ -20,7 +21,7 @@ @contextlib.contextmanager -def _rpc_child() -> typing.Iterator[Container]: +def _rpc_child() -> collections.abc.Generator[Container]: root = Container(groups=[Dependencies]) root.open() # caller-owned root; never closed here (gRPC has no root-lifecycle hook) child = root.build_child_container(scope=Scope.REQUEST)