mirror of
https://github.com/wassname/ray.git
synced 2026-09-11 12:43:20 +08:00
Add timeout param to ray.get (#6107)
This commit is contained in:
committed by
Richard Liaw
parent
e4c0843f60
commit
e3e3ad4b25
@@ -84,7 +84,8 @@ from ray.exceptions import (
|
||||
RayError,
|
||||
RayletError,
|
||||
RayTaskError,
|
||||
ObjectStoreFullError
|
||||
ObjectStoreFullError,
|
||||
RayTimeoutError,
|
||||
)
|
||||
from ray.experimental.no_return import NoReturn
|
||||
from ray.function_manager import FunctionDescriptor
|
||||
@@ -138,6 +139,8 @@ cdef int check_status(const CRayStatus& status) nogil except -1:
|
||||
raise ObjectStoreFullError(message)
|
||||
elif status.IsInterrupted():
|
||||
raise KeyboardInterrupt()
|
||||
elif status.IsTimedOut():
|
||||
raise RayTimeoutError(message)
|
||||
else:
|
||||
raise RayletError(message)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user