ソースを参照

Remove the unnecessary sleep in most services

Yentl Van Tendeloo 7 年 前
コミット
0ff1293a29
3 ファイル変更4 行追加6 行削除
  1. 0 1
      services/HUTN/main.py
  2. 0 1
      services/JSON/main.py
  3. 4 4
      services/LoLA/main.py

+ 0 - 1
services/HUTN/main.py

@@ -8,7 +8,6 @@ from modelverse import *
 import os
 
 import time
-time.sleep(1)
 init(sys.argv[1])
 login("HUTN", "HUTN")
 

+ 0 - 1
services/JSON/main.py

@@ -5,7 +5,6 @@ import os
 import json
 
 import time
-time.sleep(1)
 init(sys.argv[1])
 login("JSON", "JSON")
 

+ 4 - 4
services/LoLA/main.py

@@ -1,9 +1,12 @@
 #!/usr/bin/env python
+import sys
+sys.path.append("wrappers")
+
 from modelverse import *
 from subprocess import Popen, PIPE
 import json
 
-init(address)
+init(sys.argv[1])
 login("test_service", "my_password")
 
 def lola_service(port):
@@ -29,12 +32,9 @@ def lola_service(port):
     service_set(port, path.rstrip(','))
 
 service_register("lola", lola_service)
-print("Registered")
 
 while raw_input() != "STOP":
     # Stay active, as we shouldn't exit while the service is running!
     pass
-print("Stopping")
 
 service_stop()
-print("Service halted")