Skip to content

[Core] specifying runtime_env using conda env fullpath no work #50720

@IMSUVEN

Description

@IMSUVEN

What happened + What you expected to happen

bug: specifying runtime_env using conda env fullpath no work

expected behavior: specifying any existing conda env fullpath for ray.init can be working

logs:

ValueError: The given conda environment './custom' from the runtime env {'_ray_commit': 'c2e38f7b75be223c0c033986472daada8622d64f', 'conda': './custom'} doesn't exist from the output of `conda info --json`. You can only specify an env that already exists. Please make sure to create an env ./custom

Versions / Dependencies

ray: 2.42.1
python: 3.10

Reproduction script

  1. start ray cluster in another python env
  2. create a new python conda env for ray client
conda create --prefix ./custom python

# for simulate no this env in `conda info --json`
rm ~/.conda/environments.txt

conda activate ./custom
pip install ray[default]
import ray
runtime_env = {
    "conda":  "./custom"
}
ray.init(address="ray://ip_host:10001",runtime_env=runtime_env)
# Error

Issue Severity

High: It blocks me from completing my task.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1Issue that should be fixed within a few weekscommunity-backlogcoreIssues that should be addressed in Ray Corecore-runtime-envIssues related to Ray environment dependenciesquestionJust a question :)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions