mirror of
https://github.com/wassname/ray.git
synced 2026-06-29 04:44:28 +08:00
Prohibit returning actor handles and also update actor documentation. (#1246)
* Prohibit returning actor handles and also update actor documentation. * Clarify documentation.
This commit is contained in:
committed by
Philipp Moritz
parent
2ae5a8484f
commit
477a40f76d
@@ -347,6 +347,11 @@ class Worker(object):
|
||||
"do this, you can wrap the ObjectID in a list and "
|
||||
"call 'put' on it (or return it).")
|
||||
|
||||
if isinstance(value, ray.actor.ActorHandleParent):
|
||||
raise Exception("Calling 'put' on an actor handle is currently "
|
||||
"not allowed (similarly, returning an actor "
|
||||
"handle from a remote function is not allowed).")
|
||||
|
||||
# Serialize and put the object in the object store.
|
||||
try:
|
||||
self.store_and_register(object_id, value)
|
||||
|
||||
Reference in New Issue
Block a user