networkx.algorithms.shortest_paths.generic.
has_path
Return True if G has a path from source to target, False otherwise.