Skip to content

Commit

Permalink
[hotfix][tune] fix get_sync_client. (ray-project#6525)
Browse files Browse the repository at this point in the history
ujvl authored and richardliaw committed Dec 18, 2019

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent 978d72b commit ec4f8d5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/ray/tune/sync_client.py
Original file line number Diff line number Diff line change
@@ -32,11 +32,13 @@ def get_sync_client(sync_function):
"""Returns a sync client.
Args:
sync_function (str|function): Sync function.
sync_function (Optional[str|function]): Sync function.
Raises:
ValueError if sync_function is malformed.
"""
if sync_function is None:
return None
if isinstance(sync_function, types.FunctionType):
client_cls = FunctionBasedClient
elif isinstance(sync_function, str):

0 comments on commit ec4f8d5

Please sign in to comment.