Streamlit-authenticator module serving blank page after login

I am getting a blank page after successful login using the streamlit-authenticator. If I reload the page, the blank page no longer shows and page displays correctly with all the data. This only happens in the docker instance in production, on localhost it runs fine.

Here is what I am getting from developers tool:
main.cc5b8325.js:2 Uncaught TypeError: Cannot read properties of undefined (reading ‘vertical’)
at _i (main.cc5b8325.js:2:4196413)
at aa (main.cc5b8325.js:2:2222882)
at $s (main.cc5b8325.js:2:2275226)
at Rl (main.cc5b8325.js:2:2262472)
at _l (main.cc5b8325.js:2:2262400)
at El (main.cc5b8325.js:2:2262263)
at gl (main.cc5b8325.js:2:2259229)
at main.cc5b8325.js:2:2208674
at t.unstable_runWithPriority (main.cc5b8325.js:2:3046033)
at Xo (main.cc5b8325.js:2:2208451)
_i @ main.cc5b8325.js:2
aa @ main.cc5b8325.js:2
$s @ main.cc5b8325.js:2
Rl @ main.cc5b8325.js:2
_l @ main.cc5b8325.js:2
El @ main.cc5b8325.js:2
gl @ main.cc5b8325.js:2
(anonymous) @ main.cc5b8325.js:2
t.unstable_runWithPriority @ main.cc5b8325.js:2
Xo @ main.cc5b8325.js:2
Ko @ main.cc5b8325.js:2
$o @ main.cc5b8325.js:2
fl @ main.cc5b8325.js:2
enqueueSetState @ main.cc5b8325.js:2
m.setState @ main.cc5b8325.js:2
(anonymous) @ main.cc5b8325.js:2
setTimeout (async)
Sp.handleDeltaMsg @ main.cc5b8325.js:2
delta @ main.cc5b8325.js:2
(anonymous) @ main.cc5b8325.js:2
Sp.handleMessage @ main.cc5b8325.js:2
handleMessage @ main.cc5b8325.js:2
await in handleMessage (async)
websocket.onmessage @ main.cc5b8325.js:2

Here is my config:

  • run in docker
  • docker runs in AWS EC2 instance, Amazon Linux
  • content served through nginx
  • streamlit version 1.3.1
  • streamlit_authenticator~=0.3.1

Please advice how can I solve this issue?

Did you manage to figure it out? I’m having the same problem, except the page only shows on first load, after that it is blank on every refresh.

I’m using:

  • streamlit 1.31.1 (but also tested with 1.29 and 1.32)
  • streamlit-authenticator 0.3.1
  • docker to run the application (for local development and in AWS)
1 Like

Well basically I went back in time when it used to work, and applied that code. I had no idea what specific part of the new code broke it.

This is the code that now works for me again:

    def display_login(self):
        name, authentication_status, username = (self.authenticator.login('main', fields={'Form name': 'Login'}))

        if authentication_status:
            self.authenticator.logout('Logout', 'main')
            if username == 'Bob':
                st.write(f'Welcome *{name}*')
                tabs.display_tabs()
            elif username == 'Tom':
                st.write(f'Welcome *{name}*')
                tabs.display_tabs()
        elif authentication_status == False:
            st.error('Username/password is incorrect')
        elif authentication_status == None:
            st.warning('Please enter your username and password')

I code that stopped working had worked with session states and containers. Not sure if that was causing the issue but it is now working again.

JK

I have the same issue
I have tabs and containers as well… i’d appreciate some insights on what the cause maybe