mtyrrell commited on
Commit
f2efe55
·
1 Parent(s): a0ca5cb
Files changed (1) hide show
  1. app.py +12 -12
app.py CHANGED
@@ -26,15 +26,15 @@ from io import BytesIO
26
  logger = logging.getLogger(__name__)
27
 
28
  # Local
29
- from dotenv import load_dotenv
30
- load_dotenv()
31
 
32
 
33
  # Main app logic
34
  def main():
35
  # Temporarily set authentication to True for testing
36
  if 'authenticated' not in st.session_state:
37
- st.session_state['authenticated'] = True
38
 
39
  if st.session_state['authenticated']:
40
  # Remove login success message for testing
@@ -183,15 +183,15 @@ def main():
183
 
184
 
185
  # Comment out for testing
186
- # else:
187
- # username = st.text_input("Username")
188
- # password = st.text_input("Password", type="password")
189
- # if st.button("Login"):
190
- # if validate_login(username, password):
191
- # st.session_state['authenticated'] = True
192
- # st.rerun()
193
- # else:
194
- # st.error("Incorrect username or password")
195
 
196
 
197
 
 
26
  logger = logging.getLogger(__name__)
27
 
28
  # Local
29
+ # from dotenv import load_dotenv
30
+ # load_dotenv()
31
 
32
 
33
  # Main app logic
34
  def main():
35
  # Temporarily set authentication to True for testing
36
  if 'authenticated' not in st.session_state:
37
+ st.session_state['authenticated'] = False
38
 
39
  if st.session_state['authenticated']:
40
  # Remove login success message for testing
 
183
 
184
 
185
  # Comment out for testing
186
+ else:
187
+ username = st.text_input("Username")
188
+ password = st.text_input("Password", type="password")
189
+ if st.button("Login"):
190
+ if validate_login(username, password):
191
+ st.session_state['authenticated'] = True
192
+ st.rerun()
193
+ else:
194
+ st.error("Incorrect username or password")
195
 
196
 
197