Spaces:
Sleeping
Sleeping
= commited on
Commit ·
af4ae78
1
Parent(s): adcee77
modify sentences
Browse files
pages/provide_sentences_mongo.py
CHANGED
|
@@ -120,9 +120,6 @@ def add_new_sentences2():
|
|
| 120 |
'wolof': sentence_2
|
| 121 |
})
|
| 122 |
|
| 123 |
-
# recuperate the already saved sentences (for the moment french/wolof)
|
| 124 |
-
sentences, deleted = db_manager.load_data_frames()
|
| 125 |
-
|
| 126 |
# clean the inputs' contents
|
| 127 |
st.session_state.left_sentence = ''
|
| 128 |
st.session_state.right_sentence = ''
|
|
@@ -162,10 +159,6 @@ def modify_line():
|
|
| 162 |
|
| 163 |
st.session_state['right_sentence'] = sentences[sentences['_id'] == number][sentences.columns.tolist()[2]].to_list()[0]
|
| 164 |
|
| 165 |
-
for key in st.session_state:
|
| 166 |
-
|
| 167 |
-
del st.session_state[key]
|
| 168 |
-
|
| 169 |
sentences.drop(index = sentences[sentences['_id'] == number].index, inplace=True)
|
| 170 |
|
| 171 |
# add the document to update to the updated documents
|
|
|
|
| 120 |
'wolof': sentence_2
|
| 121 |
})
|
| 122 |
|
|
|
|
|
|
|
|
|
|
| 123 |
# clean the inputs' contents
|
| 124 |
st.session_state.left_sentence = ''
|
| 125 |
st.session_state.right_sentence = ''
|
|
|
|
| 159 |
|
| 160 |
st.session_state['right_sentence'] = sentences[sentences['_id'] == number][sentences.columns.tolist()[2]].to_list()[0]
|
| 161 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 162 |
sentences.drop(index = sentences[sentences['_id'] == number].index, inplace=True)
|
| 163 |
|
| 164 |
# add the document to update to the updated documents
|