Skip to content

[tune] Dashboard server crashing (AttributeError: module 'grpc' has no attribute 'server') #8153

@nyxynyx

Description

@nyxynyx

How to fix the error AttributeError: module 'grpc' has no attribute 'server' when running Tune?

When I try to start Ray Tune with the coding:

    ray.init()
    reporter = CLIReporter()
    reporter.add_metric_column('x')

    analysis = tune.run(
        traintest,
        config={"lr": tune.grid_search([0.1, 0.01])},
        progress_reporter=reporter
    )

I get the error

WARNING worker.py:1072 -- The reporter on node testserver failed with the following error:
Traceback (most recent call last):
  File "/opt/anaconda3/envs/foo/lib/python3.7/site-packages/ray/reporter.py", line 248, in <module>
    reporter.run()
  File "/opt/anaconda3/envs/foo/lib/python3.7/site-packages/ray/reporter.py", line 197, in run
    server = grpc.server(thread_pool, options=(("grpc.so_reuseport", 0), ))
AttributeError: module 'grpc' has no attribute 'server'

The trials still run, but the dashboard shows an error message

image

Has anyone seen this error before? How can we fix this? Thanks!

$ pip freeze | grep -i grpc
grpcio==1.28.1

Ray version and other system information (Python version, TensorFlow version, OS):

  • ray 0.8.4
  • Python 3.7.3
  • Pytorch 1.3.1
  • Ubuntu 18.04

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionJust a question :)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions