henryL7 commited on
Commit
d4742e4
·
1 Parent(s): 47aa885
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -17,7 +17,7 @@ def restart_space():
17
  print(TOKEN)
18
  API.restart_space(repo_id=REPO_ID, token=TOKEN)
19
 
20
- restart_space()
21
 
22
  demo = gr.Blocks(css=custom_css)
23
  with demo:
@@ -68,6 +68,7 @@ with demo:
68
 
69
 
70
  scheduler = BackgroundScheduler()
71
- scheduler.add_job(restart_space, "interval", seconds=180)
72
  scheduler.start()
73
- demo.queue(default_concurrency_limit=40).launch()
 
 
17
  print(TOKEN)
18
  API.restart_space(repo_id=REPO_ID, token=TOKEN)
19
 
20
+ # restart_space()
21
 
22
  demo = gr.Blocks(css=custom_css)
23
  with demo:
 
68
 
69
 
70
  scheduler = BackgroundScheduler()
71
+ scheduler.add_job(restart_space, "interval", seconds=300)
72
  scheduler.start()
73
+ # demo.queue().launch()
74
+ demo.launch()