Skip to content

Observations/Issues following steps https://docs.ray.io/en/latest/ray-contribute/development.html #52169

@jaganmolleti7

Description

@jaganmolleti7

What happened + What you expected to happen

Using https://docs.ray.io/en/latest/ray-contribute/development.html to setup for Ray development.

on Ubuntu Linux --> 6.11.0-19-generic #19~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon Feb 17 11:51:52 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

Most part of setting the environment looked fine and I appreciate for the same, and I've eventually felt have found issues to completely finish the setup. Some part of it looks like with versions which is expected to change. Let me list them down in same order. I shall list brief title and the logs under the same. So bear with me if logs make visual appeal bad. I planned to put them together instead of separate tickets, as that is right way in this case

1. ray wheels install got halted. This is more of doc update in my view, as once the venv is invoked the issue got resolved. If documentation calls it out, the setup process can be enhanced well.

ray$ pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/latest/ray-3.0.0.dev0-cp39-cp39-manylinux2014_x86_64.whl
error: externally-managed-environment

× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
python3-xyz, where xyz is the package you are trying to
install.

If you wish to install a non-Debian-packaged Python package,
create a virtual environment using python3 -m venv path/to/venv.
Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
sure you have python3-full installed.

If you wish to install a non-Debian packaged Python application,
it may be easiest to use pipx install xyz, which will manage a
virtual environment for you. Make sure you have pipx installed.

See /usr/share/doc/python3.12/README.venv for more information.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 668 for the detailed specification.

2. ray wheels install halted again for version incompatibility.

pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/latest/ray-3.0.0.dev0-cp39-cp39-manylinux2014_x86_64.whl
ERROR: ray-3.0.0.dev0-cp39-cp39-manylinux2014_x86_64.whl is not a supported wheel on this platform.

To fix it,

I ran this

pip install "ray[default]" to bring to latest version and match it to python version.

but I felt still same error. issue persisted.

Looks like this ray wheels install is not required anymore, as pip install "ray[default]" happened.

3. instruction including clang12 failed.

(ray-venv) jaganmolleti@jaganlx:~/Ray/RayGitHub/ray$ sudo apt-get install -y build-essential curl clang-12 pkg-config psmisc unzip
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package clang-12 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'clang-12' has no installation candidate

Looks like we may not really need version 12 of clang. kindly confirm on the same. so instead went ahead with below.

sudo apt-get update
sudo apt-get install -y build-essential curl clang pkg-config psmisc unzip

4. at the section/step Building Ray on Linux & MacOS (full)
it is not clear where the build is and what to do. Like I was expecting some package/image of the build process. It would help seeing instruction of the same or clarify on the same.

  1. pip install -c python/requirements_compiled.txt -r python/requirements/lint-requirements.txt gave error(https://docs.ray.io/en/latest/ray-contribute/development.html )

Attempting uninstall: rich
Found existing installation: rich 14.0.0
Uninstalling rich-14.0.0:
Successfully uninstalled rich-14.0.0
Attempting uninstall: requests
Found existing installation: requests 2.32.3
Uninstalling requests-2.32.3:
Successfully uninstalled requests-2.32.3
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
textual 3.0.1 requires rich>=13.3.3, but you have rich 13.3.2 which is incompatible.

6. all the packages install took time, but the bazel build command gave error.

bazel build -c fastbuild //:ray_pkg
Command 'bazel' not found, but can be installed with:
sudo apt install bazel-bootstrap

after the apt install,

bazel build -c fastbuild //:ray_pkg
ERROR: The project you're trying to build requires Bazel 6.5.0 (specified in /home/jaganmolleti/Ray/RayGitHub/ray/.bazelversion), but it wasn't found in /usr/bin.

You can install the required Bazel version via apt:
sudo apt update && sudo apt install bazel-6.5.0

If this doesn't work, check Bazel's installation instructions for help:
https://docs.bazel.build/versions/master/install-ubuntu.html

sudo apt install bazel-6.5.0
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package bazel-6.5.0
E: Couldn't find any package by glob 'bazel-6.5.0'

7. after all the above steps. ray environment which was working before this steps, broke. Looks like Ray is yet to be fully supported on python 3.12. ?

python -c "import ray; print(ray.version)"
Traceback (most recent call last):
File "", line 1, in
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/init.py", line 114, in
from ray._private.worker import ( # noqa: E402,F401
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/_private/worker.py", line 55, in
import ray.actor
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/actor.py", line 39, in
from ray.util.tracing.tracing_helper import (
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/util/tracing/tracing_helper.py", line 29, in
from ray.runtime_context import get_runtime_context
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/runtime_context.py", line 9, in
from ray.runtime_env import RuntimeEnv
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/runtime_env/init.py", line 2, in
from ray.runtime_env.runtime_env import RuntimeEnv, RuntimeEnvConfig # noqa: E402,F401
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/runtime_env/runtime_env.py", line 10, in
from ray._private.runtime_env.conda import get_uri as get_conda_uri
File "/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/_private/runtime_env/conda.py", line 17, in
from ray._common.utils import (
ImportError: cannot import name 'get_or_create_event_loop' from 'ray._common.utils' (/home/jaganmolleti/ray-venv/lib/python3.12/site-packages/ray/_common/utils.py)

Versions / Dependencies

on Ubuntu Linux --> 6.11.0-19-generic #19~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon Feb 17 11:51:52 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

Ubuntu clang version 18.1.3 (1ubuntu1)

ray version I couldnt copy, but it is the latest source code as on April 9, 2025 IST (noon time)

Reproduction script

Just followed the instructions at

https://docs.ray.io/en/latest/ray-contribute/development.html

and copied the errors in the above description.

Actually it blocked me, but kept the severity at Low as it is not production issue.

Issue Severity

Low: It annoys or frustrates me.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issue moderate in impact or severitybugSomething that is supposed to be working; but isn'tbuildcommunity-backlogdependenciesPull requests that update a dependency filedocsAn issue or change related to documentationpythonPull requests that update Python code

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions