Spaces:
Build error
Build error
Ronio Jerico Roque commited on
Commit ·
e2a65de
1
Parent(s): 7dfa00b
Fix: Add user feedback for incorrect file formats in SEO analysis
Browse files- classes/Seo.py +2 -3
classes/Seo.py
CHANGED
|
@@ -162,7 +162,6 @@ class Seo:
|
|
| 162 |
|
| 163 |
session = st.session_state.analyze
|
| 164 |
if ((self.uploaded_file or self.others or self.uploaded_file_seo) or (self.page_index or self.bounce_rate)) and session == 'clicked':
|
| 165 |
-
combined_text = ""
|
| 166 |
seo_keywords = ""
|
| 167 |
traffic_channels = ""
|
| 168 |
traffic_aqcuisition = ""
|
|
@@ -199,7 +198,7 @@ class Seo:
|
|
| 199 |
except AttributeError:
|
| 200 |
pass
|
| 201 |
except KeyError:
|
| 202 |
-
|
| 203 |
|
| 204 |
try:
|
| 205 |
df_seo = st.session_state['df_seo']
|
|
@@ -229,7 +228,7 @@ class Seo:
|
|
| 229 |
except KeyError:
|
| 230 |
pass
|
| 231 |
except TypeError:
|
| 232 |
-
|
| 233 |
|
| 234 |
# OUTPUT FOR SEO ANALYST
|
| 235 |
payload_txt_seo_keywords = {"question": seo_keywords}
|
|
|
|
| 162 |
|
| 163 |
session = st.session_state.analyze
|
| 164 |
if ((self.uploaded_file or self.others or self.uploaded_file_seo) or (self.page_index or self.bounce_rate)) and session == 'clicked':
|
|
|
|
| 165 |
seo_keywords = ""
|
| 166 |
traffic_channels = ""
|
| 167 |
traffic_aqcuisition = ""
|
|
|
|
| 198 |
except AttributeError:
|
| 199 |
pass
|
| 200 |
except KeyError:
|
| 201 |
+
st.info("Incorrect SEMRush format. Please upload a valid SEMRush file.")
|
| 202 |
|
| 203 |
try:
|
| 204 |
df_seo = st.session_state['df_seo']
|
|
|
|
| 228 |
except KeyError:
|
| 229 |
pass
|
| 230 |
except TypeError:
|
| 231 |
+
st.info("Incorrect GA4 format. Please upload a valid GA4 file.")
|
| 232 |
|
| 233 |
# OUTPUT FOR SEO ANALYST
|
| 234 |
payload_txt_seo_keywords = {"question": seo_keywords}
|