streamlit 0.72: I use file uploader to read a pickle file. the code as below.
uploaded_file = st.file_uploader(“Choose a position file”,type=‘pkl’)
if uploaded_file is not None:
df_loadedTrans = pd.read_pickle(uploaded_file)
but it only work for the first time. after I load the file, and then re-run the script. I get below error. Any idea to solve this error? Thanks.
ValueError: I/O operation on closed file.
File "c:\anaconda3\lib\site-packages\streamlit\elements\file_uploader.py", line 122, in file_uploader if file.tell() > 0: