We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5331ba6 commit a260b62Copy full SHA for a260b62
ipykernel/kernelbase.py
@@ -72,6 +72,8 @@
72
" ipykernel 6.0 (2021). {target} does not seem to return an awaitable"
73
)
74
75
+T = t.TypeVar("T")
76
+
77
78
def _accepts_parameters(meth, param_names):
79
parameters = inspect.signature(meth).parameters
@@ -801,7 +803,7 @@ def get_parent(self, channel=None):
801
803
802
804
return self._get_shell_context_var(self._shell_parent)
805
- def _get_shell_context_var(self, var: ContextVar):
806
+ def _get_shell_context_var(self, var: ContextVar[T]) -> T:
807
"""Lookup a ContextVar, falling back on the shell context
808
809
Allows for user-launched Threads to still resolve to the shell's mai context
0 commit comments