Issue with Streamlit app on AWS Beanstalk - Error: thisXXXXXXXX is not defined

Hi Streamlit Community,

I recently deployed my Streamlit app on AWS Beanstalk, and while it works perfectly fine with a private URL, I encountered an error when configuring a public URL.

The error seems to be originating from the st.file_uploader function within the Streamlit package. I’m receiving the following error message:

I’m wondering if anyone else has encountered a similar issue or has any insights into resolving it. Below is the code using st.file_uploader:

Any guidance or assistance would be greatly appreciated. Thank you in advance for your help!

Did you get any solution? I’m also facing the same issue. I have a simple python file with just st.file_uploader deployed it in elastic beanstalk (t3.small). My app works fine on local and private url of beanstalk but giving this reference error when server through public url.

no luck

Okay the solution for this is to add below two lines in nginx.conf file:

client_max_body_size 50M;
types_hash_max_size 2048;