-
Notifications
You must be signed in to change notification settings - Fork 761
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
May be _load_runtime_context can be better:
def _load_runtime_context(func: _F) -> _F:
@wraps(func) # type: ignore[misc]
def wrapper( # type: ignore[misc]
*args: typing.Tuple[typing.Any, typing.Any],
**kwargs: typing.Dict[typing.Any, typing.Any],
) -> typing.Optional[typing.Any]:
global _RUNTIME_CONTEXT # pylint: disable=global-statement
if _RUNTIME_CONTEXT is None:
with _RUNTIME_CONTEXT_LOCK:
if _RUNTIME_CONTEXT is not None:
return
...Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working