axiosError: Request failed with status code 403 in aws sagemaker studio

I am using AWS Sagemaker studio to write my app code.
streamlit version = 1.32.0
python version = 3.9.15

Line of Code:
uploaded_file = st.file_uploader(“Upload your input File”,accept_multiple_files=False, type=[‘xlsx’])

Error:
axiosError: Request failed with status code 403

I am getting the above error, while uploading an excel file.
Could you pls solve this.

I am facing this issue in all versions except 1.24.0.
But certain latest features are not compatible in this 1.24.0,

I am also facing samge Issue I tried creating a .streamlit folder but studio will not alow that I wanted to make the config file and disable the CORS funcitonality like so:

[server]
enableXsrfProtection = false
enableCORS = false