ray-project / ray

Ray is a unified framework for scaling AI and Python applications. Ray consists of a core distributed runtime and a set of AI Libraries for accelerating ML workloads.

Home Page:https://ray.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Worker] Worker crash when getting an actor name

fyrestone opened this issue · comments

What happened + What you expected to happen

Expect to return an empty name or raise an exception, but the worker crash.

[2024-05-07 11:37:17,261 C 3465 7571412] actor_manager.cc:47:  Check failed: it != actor_handles_.end() Cannot find an actor handle of id, NIL_ID. This method should be called only when you ensure actor handles exists.
*** StackTrace Information ***
0   _raylet.so                          0x0000000107dcc2bc _ZN3raylsERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEERKNS_10StackTraceE + 84 ray::operator<<()
1   _raylet.so                          0x0000000107df2e88 _ZN3ray13SpdLogMessage5FlushEv + 220 ray::SpdLogMessage::Flush()
2   _raylet.so                          0x0000000107df2cf0 _ZN3ray13SpdLogMessageD2Ev + 20 ray::SpdLogMessage::~SpdLogMessage()
3   _raylet.so                          0x0000000107dcf928 _ZN3ray6RayLogD2Ev + 52 ray::RayLog::~RayLog()
4   _raylet.so                          0x00000001073ff050 _ZNK3ray4core12ActorManager14GetActorHandleERKNS_7ActorIDE + 704 ray::core::ActorManager::GetActorHandle()
5   _raylet.so                          0x000000010742dae0 _ZNK3ray4core10CoreWorker12GetActorNameEv + 56 ray::core::CoreWorker::GetActorName()
6   _raylet.so                          0x00000001073017bc _ZL52__pyx_pw_3ray_7_raylet_10CoreWorker_23get_actor_nameP7_objectS0_ + 32 __pyx_pw_3ray_7_raylet_10CoreWorker_23get_actor_name()
7   python3.8                           0x0000000104b2afe4 method_vectorcall_NOARGS + 312 method_vectorcall_NOARGS
8   python3.8                           0x0000000104c28824 _PyEval_EvalFrameDefault + 30612 _PyEval_EvalFrameDefault
9   python3.8                           0x0000000104b1b7ac _PyFunction_Vectorcall + 416 _PyFunction_Vectorcall
10  python3.8                           0x0000000104b29cd8 property_descr_get + 108 property_descr_get
11  python3.8                           0x0000000104b7e32c _PyObject_GetMethod + 648 _PyObject_GetMethod
12  python3.8                           0x0000000104c28fcc _PyEval_EvalFrameDefault + 32572 _PyEval_EvalFrameDefault
13  python3.8                           0x0000000104c1f1ac _PyEval_EvalCodeWithName + 736 _PyEval_EvalCodeWithName
14  python3.8                           0x0000000104c915e0 run_mod + 172 run_mod
15  python3.8                           0x0000000104c8ff84 pyrun_file + 156 pyrun_file
16  python3.8                           0x0000000104c8fa14 pyrun_simple_file + 352 pyrun_simple_file
17  python3.8                           0x0000000104c8f874 PyRun_SimpleFileExFlags + 64 PyRun_SimpleFileExFlags
18  python3.8                           0x0000000104cb228c pymain_run_file + 264 pymain_run_file
19  python3.8                           0x0000000104cb18e8 pymain_run_python + 360 pymain_run_python
20  python3.8                           0x0000000104cb1728 Py_RunMain + 40 Py_RunMain
21  python3.8                           0x0000000104aee1a0 main + 56 main
22  dyld                                0x00000001820da0e0 start + 2360 start

Versions / Dependencies

Ray 2.10.0

Reproduction script

import ray

if __name__ == "__main__":
    ray.init("local")
    context = ray.get_runtime_context()
    print(context.worker.actor_name())

Issue Severity

Low: It annoys or frustrates me.