How severe does this issue affect your experience of using Ray?
- High: It blocks me to complete my task.
I was trying to build Ray 2.9.1(both C++ and Python) from scratch in WSL Ubuntu 20.04 Environment following the official guide. The build is successful. However, I encountered several issues when I wanted to build the tests and single-step debug the program to understand more about the source code.
For CPP tests, I tried to run bazel test $(bazel query 'kind(cc_test, ...)')
following the doc. It threw me with this error:
ERROR: /home/nemo/ray/BUILD.bazel:795:12: Compiling src/ray/core_worker/test/core_worker_test.cc failed: (Exit 1): gcc failed: error executing command
(cd /home/nemo/.cache/bazel/_bazel_nemo/7a958170e819e03cfcfa43da964a4968/sandbox/linux-sandbox/629/execroot/com_github_ray_project_ray && \
exec env - \
LD_LIBRARY_PATH=/usr/local/cuda/lib64:/usr/local/cuda/lib64 \
PATH='/home/nemo/.cache/bazelisk/downloads/bazelbuild/bazel-5.4.1-linux-x86_64/bin:/home/nemo/bin:/home/nemo/.modular/pkg/packages.modular.com_mojo/bin:/usr/local/cuda/bin:/home/nemo/.local/bin:/home/nemo/.cargo/bin:/home/nemo/.local/bin:/home/nemo/.modular/pkg/packages.modular.com_mojo/bin:/home/nemo/.nvm/versions/node/v14.21.3/bin:/home/nemo/anaconda3/envs/raybuild2.9.1/bin:/home/nemo/anaconda3/condabin:/usr/local/cuda/bin:/home/nemo/.local/bin:/home/nemo/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Program Files (x86)/VMware/VMware Workstation/bin:/mnt/c/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v11.1/bin:/mnt/c/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v11.1/libnvvp:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0:/mnt/c/Windows/System32/OpenSSH:/mnt/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/mnt/c/Program Files/NVIDIA Corporation/NVIDIA NvDLISR:/mnt/c/Program Files/Microsoft SQL Server/130/Tools/Binn:/mnt/c/Program Files/NVIDIA Corporation/Nsight Compute 2020.2.1:/mnt/c/WINDOWS/system32:/mnt/c/WINDOWS:/mnt/c/WINDOWS/System32/Wbem:/mnt/c/WINDOWS/System32/WindowsPowerShell/v1.0:/mnt/c/WINDOWS/System32/OpenSSH:/mnt/c/Program Files/Docker/Docker/resources/bin:/mnt/c/ProgramData/DockerDesktop/version-bin:/mnt/c/Program Files/Git/cmd:/mnt/c/Program Files/dotnet:/mnt/c/Program Files/Calibre2:/mnt/c/Program Files/Kubernetes/Minikube:/mnt/c/minikube:/mnt/c/Users/chenf/scoop/shims:/mnt/c/Users/chenf/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/chenf/AppData/Local/Programs/Microsoft VS Code/bin:/mnt/c/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64:/snap/bin' \
PWD=/proc/self/cwd \
/usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g '-std=c++0x' -MD -MF bazel-out/k8-dbg/bin/_objs/core_worker_test/core_worker_test.pic.d '-frandom-seed=bazel-out/k8-dbg/bin/_objs/core_worker_test/core_worker_test.pic.o' -fPIC -DBOOST_NO_CXX98_FUNCTION_BASE -DBOOST_ASIO_SEPARATE_COMPILATION -DCARES_STATICLIB -DBOOST_FILESYSTEM_NO_CXX20_ATOMIC_REF -DBOOST_FILESYSTEM_HAS_POSIX_AT_APIS -iquote . -iquote bazel-out/k8-dbg/bin -iquote external/com_github_redis_hiredis -iquote bazel-out/k8-dbg/bin/external/com_github_redis_hiredis -iquote external/boringssl -iquote bazel-out/k8-dbg/bin/external/boringssl -iquote external/com_github_google_flatbuffers -iquote bazel-out/k8-dbg/bin/external/com_github_google_flatbuffers -iquote external/com_google_protobuf -iquote bazel-out/k8-dbg/bin/external/com_google_protobuf -iquote external/com_google_absl -iquote bazel-out/k8-dbg/bin/external/com_google_absl -iquote external/utf8_range -iquote bazel-out/k8-dbg/bin/external/utf8_range -iquote external/zlib -iquote bazel-out/k8-dbg/bin/external/zlib -iquote external/boost -iquote bazel-out/k8-dbg/bin/external/boost -iquote external/com_github_spdlog -iquote bazel-out/k8-dbg/bin/external/com_github_spdlog -iquote external/com_google_googletest -iquote bazel-out/k8-dbg/bin/external/com_google_googletest -iquote external/nlohmann_json -iquote bazel-out/k8-dbg/bin/external/nlohmann_json -iquote external/com_github_jupp0r_prometheus_cpp -iquote bazel-out/k8-dbg/bin/external/com_github_jupp0r_prometheus_cpp -iquote external/civetweb -iquote bazel-out/k8-dbg/bin/external/civetweb -iquote external/com_github_madler_zlib -iquote bazel-out/k8-dbg/bin/external/com_github_madler_zlib -iquote external/io_opencensus_cpp -iquote bazel-out/k8-dbg/bin/external/io_opencensus_cpp -iquote external/com_github_grpc_grpc -iquote bazel-out/k8-dbg/bin/external/com_github_grpc_grpc -iquote external/com_google_googleapis -iquote bazel-out/k8-dbg/bin/external/com_google_googleapis -iquote external/upb -iquote bazel-out/k8-dbg/bin/external/upb -iquote external/com_github_cncf_udpa -iquote bazel-out/k8-dbg/bin/external/com_github_cncf_udpa -iquote external/com_envoyproxy_protoc_gen_validate -iquote bazel-out/k8-dbg/bin/external/com_envoyproxy_protoc_gen_validate -iquote external/com_github_cares_cares -iquote bazel-out/k8-dbg/bin/external/com_github_cares_cares -iquote external/com_googlesource_code_re2 -iquote bazel-out/k8-dbg/bin/external/com_googlesource_code_re2 -iquote external/envoy_api -iquote bazel-out/k8-dbg/bin/external/envoy_api -iquote external/opencensus_proto -iquote bazel-out/k8-dbg/bin/external/opencensus_proto -iquote external/msgpack -iquote bazel-out/k8-dbg/bin/external/msgpack -iquote external/io_opencensus_proto -iquote bazel-out/k8-dbg/bin/external/io_opencensus_proto -iquote external/rules_cc -iquote bazel-out/k8-dbg/bin/external/rules_cc -iquote external/bazel_tools -iquote bazel-out/k8-dbg/bin/external/bazel_tools -Ibazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/gcs -Ibazel-out/k8-dbg/bin/external/com_github_redis_hiredis/_virtual_includes/hiredis -Ibazel-out/k8-dbg/bin/_virtual_includes/node_manager_rpc -Ibazel-out/k8-dbg/bin/_virtual_includes/grpc_common_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/stats_metric -Ibazel-out/k8-dbg/bin/src/ray/util/_virtual_includes/util -Ibazel-out/k8-dbg/bin/_virtual_includes/aligned_alloc -Ibazel-out/k8-dbg/bin/_virtual_includes/sha256 -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/protobuf_nowkt -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/protobuf_lite -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/arena -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/arena_align -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/stubs/_virtual_includes/lite -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/port_def -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/arena_allocation_policy -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/arena_config -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/arena_cleanup -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/string_block -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/varint_shuffle -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/io -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/io_win32 -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/gzip_stream -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/stubs/_virtual_includes/stubs -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/printer -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/zero_copy_sink -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/io/_virtual_includes/tokenizer -Ibazel-out/k8-dbg/bin/external/com_github_spdlog/_virtual_includes/spdlog -Ibazel-out/k8-dbg/bin/external/com_github_jupp0r_prometheus_cpp/pull/_virtual_includes/pull -Ibazel-out/k8-dbg/bin/external/com_github_jupp0r_prometheus_cpp/core/_virtual_includes/core -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/asio -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/event_stats -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/ray_config -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/grpc_util -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/status -Ibazel-out/k8-dbg/bin/external/com_google_googleapis -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src -Ibazel-out/k8-dbg/bin/external/com_github_grpc_grpc -Ibazel-out/k8-dbg/bin/external/com_github_cncf_udpa -Ibazel-out/k8-dbg/bin/external/com_envoyproxy_protoc_gen_validate -Ibazel-out/k8-dbg/bin/external/envoy_api -Ibazel-out/k8-dbg/bin/external/opencensus_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/_virtual_includes/protobuf -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/protobuf -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/any_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/api_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/source_context_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/type_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/duration_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/empty_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/field_mask_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/struct_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/timestamp_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/wrappers_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/compiler/_virtual_includes/importer -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/delimited_message_util -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/differencer -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/field_mask_util -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/json_util -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/json -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/parser -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/descriptor_traits -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/lexer -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/message_path -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/zero_copy_buffered_stream -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/untyped_message -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/type_resolver_util -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/descriptor_legacy -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/unparser -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/json/_virtual_includes/writer -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/util/_virtual_includes/time_util -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/id -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/constants -Ibazel-out/k8-dbg/bin/external/msgpack/_virtual_includes/msgpack -Ibazel-out/k8-dbg/bin/external/msgpack/_virtual_includes/_msgpack -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/compiler/_virtual_includes/plugin_proto -Ibazel-out/k8-dbg/bin/external/com_google_protobuf/src/google/protobuf/_virtual_includes/descriptor_proto -Ibazel-out/k8-dbg/bin/_virtual_includes/ray_common -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/file_system_monitor -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/memory_monitor -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/network -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/ray_syncer -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/task_common -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/ray_object -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/runtime_env -Ibazel-out/k8-dbg/bin/src/ray/common/_virtual_includes/test_util -Ibazel-out/k8-dbg/bin/_virtual_includes/stats_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/reporter_rpc -Ibazel-out/k8-dbg/bin/_virtual_includes/gcs_client_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/gcs_pub_sub_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/gcs_service_rpc -Ibazel-out/k8-dbg/bin/_virtual_includes/pubsub_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/pubsub_rpc -Ibazel-out/k8-dbg/bin/_virtual_includes/redis_client -Ibazel-out/k8-dbg/bin/_virtual_includes/redis_store_client -Ibazel-out/k8-dbg/bin/_virtual_includes/plasma_client -Ibazel-out/k8-dbg/bin/_virtual_includes/raylet_client_lib -Ibazel-out/k8-dbg/bin/_virtual_includes/worker_rpc -isystem external/boringssl/src/include -isystem bazel-out/k8-dbg/bin/external/boringssl/src/include -isystem external/com_github_google_flatbuffers/include -isystem bazel-out/k8-dbg/bin/external/com_github_google_flatbuffers/include -isystem external/zlib -isystem bazel-out/k8-dbg/bin/external/zlib -isystem external/boost -isystem bazel-out/k8-dbg/bin/external/boost -isystem external/boost/libs/math/include_private -isystem bazel-out/k8-dbg/bin/external/boost/libs/math/include_private -isystem external/com_github_spdlog -isystem bazel-out/k8-dbg/bin/external/com_github_spdlog -isystem external/com_github_spdlog/include -isystem bazel-out/k8-dbg/bin/external/com_github_spdlog/include -isystem external/com_google_googletest/googlemock -isystem bazel-out/k8-dbg/bin/external/com_google_googletest/googlemock -isystem external/com_google_googletest/googlemock/include -isystem bazel-out/k8-dbg/bin/external/com_google_googletest/googlemock/include -isystem external/com_google_googletest/googletest -isystem bazel-out/k8-dbg/bin/external/com_google_googletest/googletest -isystem external/com_google_googletest/googletest/include -isystem bazel-out/k8-dbg/bin/external/com_google_googletest/googletest/include -isystem external/nlohmann_json/single_include -isystem bazel-out/k8-dbg/bin/external/nlohmann_json/single_include -isystem external/civetweb/include -isystem bazel-out/k8-dbg/bin/external/civetweb/include -isystem external/com_github_madler_zlib -isystem bazel-out/k8-dbg/bin/external/com_github_madler_zlib -isystem external/com_github_grpc_grpc/api/include -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/api/include -isystem external/com_github_grpc_grpc/include -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/include -isystem external/com_github_grpc_grpc/src/core/ext/upb-generated -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/ext/upb-generated -isystem external/com_github_grpc_grpc/src/core/ext/upbdefs-generated -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/ext/upbdefs-generated -isystem external/com_github_grpc_grpc/src/core/api/include -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/api/include -isystem external/com_github_grpc_grpc/src/core/include -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/include -isystem external/com_github_grpc_grpc/src/core/src/core/ext/upb-generated -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/src/core/ext/upb-generated -isystem external/com_github_grpc_grpc/src/core/src/core/ext/upbdefs-generated -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/src/core/src/core/ext/upbdefs-generated -isystem external/com_github_grpc_grpc/third_party/address_sorting/include -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/third_party/address_sorting/include -isystem external/com_github_cares_cares/include -isystem bazel-out/k8-dbg/bin/external/com_github_cares_cares/include -isystem external/com_github_cares_cares -isystem bazel-out/k8-dbg/bin/external/com_github_cares_cares -isystem external/com_github_grpc_grpc/third_party/xxhash -isystem bazel-out/k8-dbg/bin/external/com_github_grpc_grpc/third_party/xxhash -fPIC '-std=c++17' -Werror -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' -c src/ray/core_worker/test/core_worker_test.cc -o bazel-out/k8-dbg/bin/_objs/core_worker_test/core_worker_test.pic.o)
# Configuration: db4ea28a0e7d68f0189ff8c0c193d95305524256120584559df094e645a19ca2
# Execution platform: @local_config_platform//:host
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
src/ray/core_worker/test/core_worker_test.cc: In member function 'int ray::core::CoreWorkerTest::GetActorPid(const ray::ActorID&, std::unordered_map<std::__cxx11::basic_string<char>, double>&)':
src/ray/core_worker/test/core_worker_test.cc:207:50: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
207 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
src/ray/core_worker/test/core_worker_test.cc: In member function 'void ray::core::CoreWorkerTest::TestActorTask(std::unordered_map<std::__cxx11::basic_string<char>, double>&)':
src/ray/core_worker/test/core_worker_test.cc:303:54: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
303 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
src/ray/core_worker/test/core_worker_test.cc:351:52: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
351 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
src/ray/core_worker/test/core_worker_test.cc: In member function 'void ray::core::CoreWorkerTest::TestActorRestart(std::unordered_map<std::__cxx11::basic_string<char>, double>&)':
src/ray/core_worker/test/core_worker_test.cc:418:54: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
418 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
src/ray/core_worker/test/core_worker_test.cc: In member function 'void ray::core::CoreWorkerTest::TestActorFailure(std::unordered_map<std::__cxx11::basic_string<char>, double>&)':
src/ray/core_worker/test/core_worker_test.cc:464:54: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
464 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
src/ray/core_worker/test/core_worker_test.cc: In member function 'virtual void ray::core::SingleNodeTest_TestDirectActorTaskSubmissionPerf_Test::TestBody()':
src/ray/core_worker/test/core_worker_test.cc:630:52: error: no matching function for call to 'ray::core::CoreWorker::SubmitActorTask(ray::ActorID&, ray::core::RayFunction&, std::vector<std::unique_ptr<ray::TaskArg> >&, ray::core::TaskOptions&, std::vector<ray::rpc::ObjectReference>&)'
630 | actor_id, func, args, options, task_returns);
| ^
In file included from src/ray/core_worker/test/core_worker_test.cc:15:
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate: 'ray::Status ray::core::CoreWorker::SubmitActorTask(const ray::ActorID&, const ray::core::RayFunction&, const std::vector<std::unique_ptr<ray::TaskArg> >&, const ray::core::TaskOptions&, int, bool, const string&, std::vector<ray::rpc::ObjectReference>&, ray::TaskID)'
935 | Status SubmitActorTask(const ActorID &actor_id,
| ^~~~~~~~~~~~~~~
bazel-out/k8-dbg/bin/_virtual_includes/core_worker_lib/ray/core_worker/core_worker.h:935:10: note: candidate expects 9 arguments, 5 provided
INFO: Elapsed time: 85.640s, Critical Path: 84.45s
INFO: 131 processes: 88 internal, 43 linux-sandbox.
FAILED: Build did NOT complete successfully
//:accessor_test NO STATUS
//:actor_manager_test NO STATUS
//:callback_reply_test NO STATUS
//:chaos_redis_store_client_test NO STATUS
//:cluster_resource_manager_test NO STATUS
//:cluster_resource_scheduler_2_test NO STATUS
//:cluster_resource_scheduler_test NO STATUS
//:cluster_task_manager_test NO STATUS
//:concurrency_group_manager_test NO STATUS
//:core_worker_resubmit_queue_test NO STATUS
//:create_request_queue_test NO STATUS
//:dependency_manager_test NO STATUS
//:dependency_resolver_test NO STATUS
//:direct_actor_transport_mock_test NO STATUS
//:direct_actor_transport_test NO STATUS
.... (a lot of tests with NO STATUS)
//src/ray/util/tests:sample_test NO STATUS
//src/ray/util/tests:sequencer_test NO STATUS
//src/ray/util/tests:signal_test NO STATUS
//src/ray/util/tests:throttler_test NO STATUS
//src/ray/util/tests:util_test NO STATUS
//:core_worker_test FAILED TO BUILD
//:actor_creator_test PASSED in 1.5s
//:actor_submit_queue_test PASSED in 1.8s
//:asio_test PASSED in 1.6s
Then I reran the tests with the filter bazel test $(bazel query 'kind(cc_test, ...)') --test_filter=actor_manager_test
, this time more tests passed (but it seems the whole test suites still get built and ran, which mean the filter does not work), but the core_worker_test still failed with the same error.
Then for the Python test, I tried this python -m pytest -v -s python/ray/tests/test_basic.py
The first few tests passed, however, the following tests failed with the errors thrown “circular imports” I also checked the GitHub issues on this but it seems none of them can solve my case.
For example,
def test_import_ray_does_not_import_grpc():
# First unload grpc and ray
if "grpc" in sys.modules:
del sys.modules["grpc"]
if "ray" in sys.modules:
del sys.modules["ray"]
# Then import ray from scratch
> import ray # noqa: F401
python/ray/tests/test_basic.py:1129:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
python/ray/__init__.py:75: in <module>
_configure_system()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
def _configure_system():
import os
import platform
import sys
"""Wraps system configuration to avoid 'leaking' variables into ray."""
# Sanity check pickle5 if it has been installed.
if "pickle5" in sys.modules:
if sys.version_info >= (3, 8):
logger.warning(
"Package pickle5 becomes unnecessary in Python 3.8 and above. "
"Its presence may confuse libraries including Ray. "
"Please uninstall the package."
)
import pkg_resources
try:
version_info = pkg_resources.require("pickle5")
version = tuple(int(n) for n in version_info[0].version.split("."))
if version < (0, 0, 10):
logger.warning(
"Although not used by Ray, a version of pickle5 that leaks memory "
"is found in the environment. Please run 'pip install pickle5 -U' "
"to upgrade."
)
except pkg_resources.DistributionNotFound:
logger.warning(
"You are using the 'pickle5' module, but "
"the exact version is unknown (possibly carried as "
"an internal component by another module). Please "
"make sure you are using pickle5 >= 0.0.10 because "
"previous versions may leak memory."
)
# Importing psutil & setproctitle. Must be before ray._raylet is
# initialized.
thirdparty_files = os.path.join(
os.path.abspath(os.path.dirname(__file__)), "thirdparty_files"
)
sys.path.insert(0, thirdparty_files)
if (
platform.system() == "Linux"
and "Microsoft".lower() in platform.release().lower()
):
import ray._private.compat # noqa: E402
> ray._private.compat.patch_psutil()
E AttributeError: partially initialized module 'ray' has no attribute '_private' (most likely due to a circular import)
python/ray/__init__.py:60: AttributeError
python/ray/tests/test_basic.py::test_import_ray_does_not_import_grpc ⨯
The weird thing is If I ran some of the single test withpython -m pytest -v -s python/ray/tests/test_basic.py::test_put_get
, it passed, is this supposed to be normal?
python -m pytest -v -s python/ray/tests/test_basic.py::test_put_get
Test session starts (platform: linux, Python 3.9.18, pytest 7.0.1, pytest-sugar 0.9.5)
cachedir: .pytest_cache
rootdir: /home/nemo/ray, configfile: pytest.ini
plugins: forked-1.4.0, shutil-1.7.0, sugar-0.9.5, rerunfailures-11.1.2, asyncio-0.16.0, timeout-2.1.0, httpserver-1.0.6, sphinx-0.5.1.dev0, docker-tools-3.1.3, anyio-3.7.1, virtualenv-1.7.0, lazy-fixture-0.6.3
timeout: 180.0s
timeout method: signal
timeout func_only: False
collecting ... 2024-01-27 23:50:50,037 INFO worker.py:1724 -- Started a local Ray instance.
python/ray/tests/test_basic.py::test_put_get ✓ 100% ██████████
Results (5.40s):
1 passed
In general, I think the question for me is that it is not very clear about the overall development workflow (for the internal codebase). For example, with VScode, how can we build a local environment, ran and debug the tests and make sure the changes we made do not fail the tests before submitting CI?