Clarify get_node_ip_address docstring (#11881)

This commit is contained in:
dHannasch
2020-11-14 16:20:58 -07:00
committed by GitHub
parent 9fbeefd604
commit 5891759a3e
+2 -2
View File
@@ -346,14 +346,14 @@ def address_to_ip(address):
def get_node_ip_address(address="8.8.8.8:53"):
"""Determine the IP address of the local node.
"""IP address by which the local node can be reached *from* the `address`.
Args:
address (str): The IP address and port of any known live service on the
network you care about.
Returns:
The IP address of the current node.
The IP address by which the local node can be reached from the address.
"""
if ray.worker._global_node is not None:
return ray.worker._global_node.node_ip_address