Export remote functions when first used and also fix bug in which rem… (#4844)

* Export remote functions when first used and also fix bug in which remote functions and actor classes are not exported from workers during subsequent ray sessions.

* Documentation update

* Fix tests.

* Fix grammar
This commit is contained in:
Robert Nishihara
2019-05-24 13:44:39 -07:00
committed by Philipp Moritz
parent 4e281ba938
commit 49fe894e22
7 changed files with 66 additions and 52 deletions
+1 -1
View File
@@ -342,7 +342,7 @@ class FunctionActorManager(object):
# and export it later.
self._functions_to_export.append(remote_function)
return
if self._worker.mode != ray.worker.SCRIPT_MODE:
if self._worker.mode == ray.worker.LOCAL_MODE:
# Don't need to export if the worker is not a driver.
return
self._do_export(remote_function)