devve1 commited on
Commit
16dc9e5
1 Parent(s): fed2e5f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +13 -2
app.py CHANGED
@@ -9,6 +9,7 @@ import spacy
9
  import shutil
10
  import msgpack
11
  import tempfile
 
12
  import validators
13
  import numpy as np
14
  import pandas as pd
@@ -581,10 +582,20 @@ if __name__ == '__main__':
581
 
582
  @st.dialog('URL Ingested !')
583
  def url_ingested():
584
- pass
 
 
 
 
 
585
  @st.dialog('Documents Ingested !')
586
  def documents_ingested():
587
- pass
 
 
 
 
 
588
 
589
  with st.sidebar:
590
  st.divider()
 
9
  import shutil
10
  import msgpack
11
  import tempfile
12
+ import threading
13
  import validators
14
  import numpy as np
15
  import pandas as pd
 
582
 
583
  @st.dialog('URL Ingested !')
584
  def url_ingested():
585
+ main_thread = threading.main_thread()
586
+ while True:
587
+ L = threading.enumerate()
588
+ L.remove(main_thread)
589
+ for t in L:
590
+ t.join()
591
  @st.dialog('Documents Ingested !')
592
  def documents_ingested():
593
+ main_thread = threading.main_thread()
594
+ while True:
595
+ L = threading.enumerate()
596
+ L.remove(main_thread)
597
+ for t in L:
598
+ t.join()
599
 
600
  with st.sidebar:
601
  st.divider()