I have tried implementing session state as mentioned in streamlit counter example but i am getting the attribute error in my terminal
AttributeError: st.session_state has no attribute “count”. Did you forget to initialize it?
However my UI appears to be working fine.
My streamlit version is 0.84.1
import pandas as pd import streamlit as st st.title('Counter Example') if 'count' not in st.session_state: st.session_state.count = 0 increment = st.button('Increment') if increment: st.session_state.count += 1 st.write('Count = ', st.session_state.count)