Deployment Error Secrets file not found. Expected at:

Hello everyone I’m trying to deploy my app into streamlit cloud but always appears this error: Secrets file not found. Expected at: and my repo link… This issue is driving me crazy. I already delete, reboot and nothing seems to work. Could someone help me with this? Repo link: LU_Public/Formulario at main · TPPDS/LU_Public · GitHub


Hi @Kazz, welcome to the Streamlit community!

Have you followed the instructions here? The file should be created as soon as you add one or more secrets to your deployment

Best,
Randy

Yes, I followed all instructions, here’s the capture.

My guess would be having the quotes on another line like that for the private_key_id fails toml validation. Either take the return character out, or even simpler, delete everything but the “type” line and see if the error in your app goes away. If it does, then it points to having a toml error.

I tried the suggested but the problem persists :sob: Any other tests? I tried deleting the app and uploading it again but it doesn’t solve it either.

I’ve sent to this to our engineering team, as I launched it from my account and got the same error. I hope to hear back a little later today.

Best,
Randy

2 Likes

@Kazz -

Apparently this was a regression in the cloud codebase, and should be resolved now. You may need to delete and re-deploy your app for the fix to take hold.

If this doesn’t resolve your issue, please let us know!

Best,
Randy

1 Like

Thank you so much! This solve the issue :heart_eyes:

1 Like

Secrets file not found. Expected at: /app/.streamlit/secrets.toml

I received a similar error when trying to deploy my app to Heroku and Streamlit cloud. My app, which requires a private API key works perfectly when I run it locally.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.