Not being redirected according for authentication

My app is working well when run locally, but on deployment, I get the following message on Streamlit log rather than being redirected.

I am using OAuth2.0 flow. Below is the snippet of my code which handles authentciation

    creds = None
    if os.path.exists('token.pickle'):
        with open('token.pickle', 'rb') as token:
            creds = pickle.load(token)
    if not creds or not creds.valid:
        if creds and creds.expired and creds.refresh_token:
            creds.refresh(Request())
        else:
            flow = InstalledAppFlow.from_client_secrets_file(
                'credentials.json', SCOPES)
            creds = flow.run_local_server(port=8080)
        with open('token.pickle', 'wb') as token:
            pickle.dump(creds, token)
    if creds and creds.expired and creds.refresh_token:
        creds.refresh(Request()) 
        with open('token.pickle', 'wb') as token:
            pickle.dump(creds, token)

am i missing something? maybe use of some streamlit python library?

Hey Hi ! its seems like its issue by auth0 side requesting your authorization as client. make sure you return the callback.
hope you are using the official Auth0 for python if not:

pip install streamlit auth0-python

or we support our community you use other lib/plugin, check this out

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