Setting logging level not working

How severe does this issue affect your experience of using Ray?

  • Low: It annoys or frustrates me for a moment.

I’m trying to set logging level to ERROR with Ray Serve, but it’s still showing INFO logs.

...
init(runtime_env=runtime_env, include_dashboard=False, ignore_reinit_error=True, logging_level=logging.ERROR)
app = FastAPI()
logger = logging.getLogger("ray.serve")
...
serve.start()

@serve.deployment(ray_actor_options={"num_gpus": 1)
@serve.ingress(app)
class cv:
    def __init__(self):
        ...
        logger.setLevel(logging.ERROR)
        ...

cv.deploy()

Can you create a github issue? If it doesn’t work, it might be a bug in our codebase. Also how about try getting the logger from within the init method. Thanks!

Try getting the logger from within the init method doesn’t work. I created an issue. Thanks!