Spaces:
Runtime error
Runtime error
Commit
·
af18bd5
1
Parent(s):
5706ede
Update views.py
Browse files
views.py
CHANGED
|
@@ -50,14 +50,13 @@ def home():
|
|
| 50 |
docs_df = topic_model.get_document_info(subreddits_df.Text)
|
| 51 |
docs_df.to_csv('docs_with_topics_info.csv', index=False)
|
| 52 |
send_file('docs_with_topics_info.csv', as_attachment=True)
|
| 53 |
-
return
|
| 54 |
-
|
| 55 |
|
| 56 |
return render_template('index.html')
|
| 57 |
|
| 58 |
-
@views.route('/succes
|
| 59 |
-
def success(
|
| 60 |
-
return render_template('success.html'
|
| 61 |
|
| 62 |
@views.route('/error/<type_of_error>', methods=['GET'])
|
| 63 |
def error(type_of_error: str):
|
|
|
|
| 50 |
docs_df = topic_model.get_document_info(subreddits_df.Text)
|
| 51 |
docs_df.to_csv('docs_with_topics_info.csv', index=False)
|
| 52 |
send_file('docs_with_topics_info.csv', as_attachment=True)
|
| 53 |
+
return render_template('success.html', topics = topics_df.to_html(index=False), docs = docs_df.to_html(index=False))
|
|
|
|
| 54 |
|
| 55 |
return render_template('index.html')
|
| 56 |
|
| 57 |
+
@views.route('/succes', methods=['GET'])
|
| 58 |
+
def success():
|
| 59 |
+
return render_template('success.html')
|
| 60 |
|
| 61 |
@views.route('/error/<type_of_error>', methods=['GET'])
|
| 62 |
def error(type_of_error: str):
|