Spaces:
Sleeping
Sleeping
Update app.py
Browse filesfix the indent error
app.py
CHANGED
|
@@ -149,8 +149,8 @@ with st.sidebar:
|
|
| 149 |
# 1. SAFELY Check Secrets (Prevents FileNotFoundError)
|
| 150 |
try:
|
| 151 |
if "GROQ_API_KEY" in st.secrets:
|
| 152 |
-
|
| 153 |
-
|
| 154 |
except FileNotFoundError:
|
| 155 |
# If secrets.toml doesn't exist, ignore and fall back to manual entry
|
| 156 |
pass
|
|
|
|
| 149 |
# 1. SAFELY Check Secrets (Prevents FileNotFoundError)
|
| 150 |
try:
|
| 151 |
if "GROQ_API_KEY" in st.secrets:
|
| 152 |
+
st.session_state['groq_api_key'] = st.secrets["GROQ_API_KEY"]
|
| 153 |
+
st.session_state['is_key_valid'] = True
|
| 154 |
except FileNotFoundError:
|
| 155 |
# If secrets.toml doesn't exist, ignore and fall back to manual entry
|
| 156 |
pass
|