Skip to content

Commit

Permalink
[Core] Fix a detached actor bug fix when GCS actor management is off. (
Browse files Browse the repository at this point in the history
  • Loading branch information
rkooo567 committed Jun 11, 2020
1 parent 226b191 commit 3ddf8a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions python/ray/tests/test_actor_advanced.py
Original file line number Diff line number Diff line change
Expand Up @@ -712,6 +712,8 @@ def create_and_kill_actor(actor_name):
detached_actor = DetachedActor.options(name=actor_name).remote()
# Wait for detached actor creation.
assert ray.get(detached_actor.ping.remote()) == "pong"
del detached_actor
detached_actor = ray.get_actor(dup_actor_name)
ray.kill(detached_actor)
# Wait until actor dies.
actor_status = ray.actors(actor_id=detached_actor._actor_id.hex())
Expand Down
2 changes: 1 addition & 1 deletion python/ray/util/named_actors.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def _register_actor(name, actor_handle):
raise ValueError("An actor with name={} already exists".format(name))

# Add the actor to Redis if it does not already exist.
_internal_kv_put(actor_name, pickle.dumps(actor_handle))
_internal_kv_put(actor_name, pickle.dumps(actor_handle), overwrite=True)


def register_actor(name, actor_handle):
Expand Down

0 comments on commit 3ddf8a4

Please sign in to comment.