Deploy failed: connection refused

Hi Streamlit Gurus, I met the same problem. I’ve a small app, but it just fails to deploy. It runs well locally.

Could anybody have a look at it? The link address is: TOVA/TOVA.py at main · dwleeibru/TOVA · GitHub

I checked the link:Deploy an app - Streamlit Docs

For unknown reasons, I cannot find relevant (resource-related) information.

Many thanks, Jimmy ~

Hey @dwleeibru,

Can you share the error message you’re seeing?

1 Like

Hi Caroline, Many thanks for the reply.

The error msg is: The service has encountered an error while checking the health of the Streamlit app: Get “http://localhost:8501/healthz”: dial tcp IPAddress:8501: connect: connection refused

Look forward to getting your help. Best ~

It sounds like it did deploy – can you share the link to the app?

1 Like

Yes, that’s in the initial post. Please check below:

Can you share the link to the deployed app rather than the GitHub repo?

1 Like

Oh, I see.

Please check below:
https://dwleeibru-tova-tova-ecdi8g.streamlit.app/

So I checked the logs, and it looks like you might have an invalid character in your config file. Can you double check that?

1 Like

If the log is from yesterday, yes, I have copied a new one to replace it. Let me check, anyway.
I did find several threads about the connection refusal issue, but cannot find concise solutions.

I copied the config.toml from Configuration - Streamlit Docs
, replace original one and reboot, the error msg is still the same.

Weirdly, the issue still seems to be coming from the config file. I forked your repo and deleted the contents of the config file, and that resolved the issue. It’s deployed here (I had to also add a missing package to the requirements file). I’m not sure exactly what was wrong with the config file, but it seems like it could be an invalid/invisible character potentially

1 Like

Thank you so much for the help. May I ask: what is the missing package (could you please paste it to the reply so I can work out from my end)? and you remove all the content of config file?

The missing package was streamlit-aggrid. Yup, I just removed the contents of the config file – probably overkill, you could probably also just go through and make sure there aren’t any funky characters

1 Like

Many many thanks. If I reboot from my end, will your https://carolinedlu-tova-tova-0483p4.streamlit.app/ be killed?

Nope, it’s a separate repo

1 Like

Yes, it’s solved after I delete the content of config.toml.
If I find out what’s wrong, I’ll post it here.
I really appreciate your help. :smile:

1 Like

Hey @dwleeibru ,

Can you share the error message/SS you are getting. Also, where are you trying to deploy the app?
Is it Azure app service or VM?

regards,
-Chetan

Hi, thanks for your reply to this query. The error msg is: The service has encountered an error while checking the health of the Streamlit app: Get “http://localhost:8501/healthz”: dial tcp IPAddress:8501: connect: connection refused

The problem is becasue of the config.toml file that I copied from the tutorial. For unknown reason I’ve not figured out, it will cause connection refusal. I still have no time to check which part of the config.toml causes this problem. Thanks ~

Hi Caroline, sorry to bother you again. I meet a new issue of the same program.
The execution has no error message, however, the web-version fails to generate an excel file, but the local version has no problem with that. I leave the config.toml empty.

The link to the program is
https://carolinedlu-tova-tova-0483p4.streamlit.app/
or
https://dwleeibru-tova-tova-ecdi8g.streamlit.app/

The link of github is

Any suggetion is appreciated

If there is no error message, what makes you think that the app “fails to generate an excel file”?