[Bug][Jobs] Job submission CLI didn't work on first ray install
See original GitHub issueSearch before asking
- I searched the issues and found no similar issues.
Ray Component
Ray Serve
What happened + What you expected to happen
Assuming user starts from clean conda env and install ray packages via pip, job submission CLI doesn’t work.
Versions / Dependencies
on master and nightly
Reproduction script
Basically create new conda, install nightly, install ray default, ensure we have dashboard module running, then submit simple things with CLI
conda create --name cli-jobs python=3.8
conda activate cli-jobs
pip install -U https://s3-us-west-2.amazonaws.com/ray-wheels/latest/ray-2.0.0.dev0-cp38-cp38-macosx_10_15_x86_64.whl
python -c "import ray;print(print(ray.__commit__))"
pip install `ray[default]`
ray start --head
export RAY_ADDRESS="http://127.0.0.1:8265"
ray job submit -- "echo hello"
We will repeatedly get
❯ ray job submit -- "echo hello"
Traceback (most recent call last):
File "/Users/jiaodong/anaconda3/envs/repro/bin/ray", line 8, in <module>
sys.exit(main())
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/scripts/scripts.py", line 1989, in main
return cli()
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 1128, in __call__
return self.main(*args, **kwargs)
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 1053, in main
rv = self.invoke(ctx)
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 1395, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/click/core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/dashboard/modules/job/cli.py", line 99, in job_submit
job_id = client.submit_job(
File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/dashboard/modules/job/sdk.py", line 213, in submit_job
return JobSubmitResponse(**r.json()).job_id
TypeError: __init__() got an unexpected keyword argument 'result'
Where from dashboard module logs it suggests:
64 2021-11-23 12:49:40,808 ERROR utils.py:132 -- Handle POST /api/jobs/ failed.
65 Traceback (most recent call last):
66 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/dashboard/utils.py", line 130, in _handler_route
67 return await handler(bind_info.instance, req)
68 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/dashboard/modules/job/job_head.py", line 39, in check
69 ray.init(address="auto", namespace=RAY_INTERNAL_JOBS_NAMESPACE)
70 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/_private/client_mode_hook.py", line 105, in wrapper
71 return func(*args, **kwargs)
72 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/worker.py", line 755, in init
73 builder = ray.client(address, _deprecation_warn_enabled=False)
74 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/client_builder.py", line 347, in client
75 builder = _get_builder_from_address(address)
76 File "/Users/jiaodong/anaconda3/envs/repro/lib/python3.8/site-packages/ray/client_builder.py", line 318, in _get_builder_from_address
77 assert "ClientBuilder" in dir(module), (f"Module: {module_string} does "
78 AssertionError: Module: http does not have ClientBuilder.
Note that it will work again if we try to re-start dashboard from another terminal.
Anything else
No response
Are you willing to submit a PR?
- Yes I am willing to submit a PR!
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (6 by maintainers)
Top Results From Across the Web
Quickstart Using the Ray Jobs CLI
In this guide, we will walk through the Ray Jobs CLI commands available for submitting and interacting with a Ray Job. To use...
Read more >Not all Ray CLI dependencies were found - Stack Overflow
Try pip install "ray[default]" ! Recently, Ray made its original dependency ( pip install ray ) as a minimal core library that doesn't...
Read more >T20 Automated Job submission after the cryoSPARC installation
Hi CryoSPARC Team, Is there any way with the help of script or CryoSPARC cli, we can do the T20 job submission and...
Read more >Ray 1.10: Windows support beta, enhanced job submission ...
You can run pip install -U ray to access these features and more. ... Now, in 1.10, the jobs submission CLI will automatically...
Read more >submit-job — AWS CLI 1.27.32 Command Reference
For jobs that run on EC2 resources, it overrides the vcpus parameter set in the job definition, but doesn't override any vCPU requirement...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Even though the docs say it’s an Alpa release, it would be nice to have the basic CLI job work out-of-the-box, especially when that’s in our [docs](file:///Users/jules/git-repos/ray/doc/_build/html/ray-job-submission/overview.html#job-cli-api).
Yup please add it to the release tracking spreadsheet and by looking at the PR so far I think it should be picked