Spaces:
Build error
Build error
๐ Fix: Password authentication and deprecated package
#1
by
akseljoonas
- opened
Issues Found and Fixed
Issue 1: Missing secrets.toml causes space to crash
The app requires st.secrets["app_password"] but this file isn't available in the public repo.
Fix: Modified password check to support environment variables with fallback:
if st.session_state["password"] == st.secrets.get("app_password", os.environ.get("APP_PASSWORD", "demo123")):
Issue 2: Deprecated package in requirements.txt
The package extra-streamlit-components is deprecated and not used in the code.
Fix: Removed from requirements.txt
How to Apply
- Set
APP_PASSWORDas a Space secret/environment variable in Settings - Or keep using
.streamlit/secrets.toml(works with the fix) - Update requirements.txt to remove the unused package
Files to Update
app.py- Add password fallback logicrequirements.txt- Remove deprecated package
Let me know if you'd like me to submit these changes as a PR!