diff --git a/torch/distributed/rpc/_testing/__init__.py b/torch/distributed/rpc/_testing/__init__.py index 8ac1c02f4cee4..0abd737becafb 100644 --- a/torch/distributed/rpc/_testing/__init__.py +++ b/torch/distributed/rpc/_testing/__init__.py @@ -1,9 +1,7 @@ -# mypy: allow-untyped-defs - import torch -def is_available(): +def is_available() -> bool: return hasattr(torch._C, "_faulty_agent_init")