Update app.py
Browse files
app.py
CHANGED
@@ -448,12 +448,19 @@ def generate_report():
|
|
448 |
try:
|
449 |
progress_bar.progress(20, text="π Generating Analysis Report...")
|
450 |
report_inputs = {"query": query + " Provide detailed analysis but DO NOT include Conclusion."}
|
|
|
|
|
451 |
result_container['report'] = crew_report.kickoff(inputs=report_inputs)
|
|
|
452 |
if not result_container['report']:
|
453 |
-
st.warning("β οΈ Report generation failed.")
|
454 |
-
|
|
|
|
|
455 |
except Exception as e:
|
456 |
-
|
|
|
|
|
457 |
|
458 |
|
459 |
def generate_conclusion(query, crew_conclusion, result_container, progress_bar, step):
|
|
|
448 |
try:
|
449 |
progress_bar.progress(20, text="π Generating Analysis Report...")
|
450 |
report_inputs = {"query": query + " Provide detailed analysis but DO NOT include Conclusion."}
|
451 |
+
|
452 |
+
# Attempt to generate the report
|
453 |
result_container['report'] = crew_report.kickoff(inputs=report_inputs)
|
454 |
+
|
455 |
if not result_container['report']:
|
456 |
+
st.warning("β οΈ Report generation failed. No data returned.")
|
457 |
+
else:
|
458 |
+
progress_bar.progress(40, text="β
Analysis Report Ready!")
|
459 |
+
|
460 |
except Exception as e:
|
461 |
+
# Show the exact error message
|
462 |
+
st.error(f"β Report generation error: {str(e)}")
|
463 |
+
|
464 |
|
465 |
|
466 |
def generate_conclusion(query, crew_conclusion, result_container, progress_bar, step):
|