AssertionError: Module: http does not have ClientBuilder

Hi,

I’m trying to deploy Ray Serve 2.7.0 to a cluster running on a VM in AWS for the first time. I get the following error running serve run -a $RAY_ADDRESS serve.yml:

Traceback (most recent call last):
  File "/Users/daniel/src/api-venv/bin/serve", line 8, in <module>
    sys.exit(cli())
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/ray/serve/scripts.py", line 479, in run
    ray.init(
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/ray/_private/client_mode_hook.py", line 103, in wrapper
    return func(*args, **kwargs)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/ray/_private/worker.py", line 1336, in init
    builder = ray.client(address, _deprecation_warn_enabled=False)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/ray/client_builder.py", line 376, in client
    builder = _get_builder_from_address(address)
  File "/Users/daniel/src/api-venv/lib/python3.10/site-packages/ray/client_builder.py", line 344, in _get_builder_from_address
    assert "ClientBuilder" in dir(
AssertionError: Module: http does not have ClientBuilder.

Any help would be greatly appreciated. Thanks!

This was user-error on my part. I got it working on EC2 as follows.

  1. Spin up the remote cluster.
ray up cluster_config.yml
  1. Get a remote shell on the cluster.
ray attach cluster_config.yml
  1. From the remote shell, deploy the Ray Serve app.
serve deploy serve_config.yml