Hi! I have a Streamlit application in Foundry within code workspaces. I have a bunch of user input text boxes and at the bottom I have a clear button. When I click the clear button I want it to get rid of the text. It is not getting rid of the text within the input boxes. Instead this one is telling me the experimental rerun feature isn’t available. It specifically says module ‘streamlit’ has no attribute ‘experimental_rerun’
if clear_button:
for key in st.session_state.keys():
st.session_state[key] = “”
st.info(“Inputs cleared successfully.”)
st.experimental_rerun()
I have tested this version as well. The bottom version works but only after refreshing the page so I’d much rather use experimental re-run. Is there a way to use that or something else I should be using?
if clear_button:
for key in st.session_state.keys():
st.session_state[key] = “” st.info(“Inputs cleared - please refresh the page”)