Use st.stop() raise streamlit.runtime.scriptrunner.exceptions.StopException

Using CookieManager() in streamlit_comokies_manager, using st.stop in version 1.37.0 will prompt an error: streamlit. runtime. scriptrunner. exceptions StopException, But the same code is normal in 1.36.0;Does anyone know the reason? Thank you in advance!

windows 11
python 3.10
streamlit 1.37.0
streamlit-cookies-manager 0.2.0


import streamlit as st
import jwt
from streamlit_cookies_manager import CookieManager
class Auth:

def __init__(self):
    self.cookie_manager = CookieManager()
    if not self.cookie_manager.ready():
        st.spinner()
        st.stop()
def auth_from_cookies(self):
    cookie_value = self.cookie_manager.get(COOKIE_NAME)
    if cookie_value is None:
        return None
    try:
        person_info = jwt.decode(cookie_value, JWT_SECRET, algorithms=['HS256'])
    except jwt.ExpiredSignatureError:
        return None
    except jwt.InvalidTokenError:
        return None

    return person_info

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.