Chainlit / chainlit

Build Conversational AI in minutes ⚡️
https://docs.chainlit.io
Apache License 2.0
6.76k stars 878 forks source link

Confusing log message when setting the server to listen on `0.0.0.0` #300

Closed xffxff closed 2 days ago

xffxff commented 1 year ago

When running the server using the command chainlit run app.py --host 0.0.0.0, the log output can be misleading. Despite explicitly setting the server to listen on 0.0.0.0, the log message incorrectly states that the app is available at http://localhost:8000

> chainlit run app.py --host 0.0.0.0
2023-08-21 16:32:06 - Your app is available at http://localhost:8000

This issue can be traced back to the following code: https://github.com/Chainlit/chainlit/blob/41228cc7a1016b8a70ab2e5abae05b481b962ba7/src/chainlit/config.py#L96 https://github.com/Chainlit/chainlit/blob/41228cc7a1016b8a70ab2e5abae05b481b962ba7/src/chainlit/server.py#L46-L51

I'm not sure if chainlit did it deliberately, so I didn't create a PR to fix it.

willydouhard commented 1 year ago

This is done on purpose (see here) because visiting that url in the browser won't work.