Browse Source

Remove time.sleep(3)

INADA Naoki 11 years ago
parent
commit
faea3dd9be

+ 0 - 3
frameworks/Python/bottle/setup.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/bottle/setup_py3.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY3_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/bottle/setup_pypy.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PYPY_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/django/setup.py

@@ -1,12 +1,10 @@
 import subprocess
-import time
 
 
 def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0
 
 
@@ -14,5 +12,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/django/setup_pg.py

@@ -1,12 +1,10 @@
 import subprocess
-import time
 
 
 def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=postgresql_psycopg2",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0
 
 
@@ -14,5 +12,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/django/setup_py3.py

@@ -1,12 +1,10 @@
 import subprocess
-import time
 
 
 def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY3_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0
 
 
@@ -14,5 +12,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd="django", shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/falcon/setup.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/falcon/setup_py3.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY3_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/falcon/setup_pypy.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PYPY_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/flask/setup_nginxuwsgi.py

@@ -1,7 +1,6 @@
 import multiprocessing
 import os
 import subprocess
-import time
 
 
 CWD = os.path.abspath(os.path.dirname(__file__))
@@ -21,7 +20,6 @@ def start(args, logfile, errfile):
             "{0}/uwsgi --ini uwsgi.ini --processes {1} --wsgi app:app".format(bin_dir, NCPU*3),
             shell=True, cwd=CWD, stderr=errfile, stdout=logfile)
 
-        time.sleep(3)
         return 0
     except subprocess.CalledProcessError:
         return 1
@@ -34,5 +32,4 @@ def stop(logfile, errfile):
 
     subprocess.call(bin_dir + '/uwsgi --stop /tmp/uwsgi.pid',
                     shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/flask/setup_py2.py

@@ -1,7 +1,6 @@
 from __future__ import print_function
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -15,7 +14,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -23,5 +21,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/flask/setup_py3.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY3_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/flask/setup_pypy.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PYPY_GUNICORN app:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/pyramid/setup_py2.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY2_GUNICORN wsgi:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 3
frameworks/Python/pyramid/setup_py3.py

@@ -1,6 +1,5 @@
 import os
 import subprocess
-import time
 
 CWD = os.path.dirname(__file__)
 
@@ -9,7 +8,6 @@ def start(args, logfile, errfile):
     subprocess.Popen(
         "$PY3_GUNICORN wsgi:app -c gunicorn_conf.py",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0
 
 
@@ -17,5 +15,4 @@ def stop(logfile, errfile):
     subprocess.call(
         "kill `cat gunicorn.pid`",
         cwd=CWD, stderr=errfile, stdout=logfile, shell=True)
-    time.sleep(3)
     return 0

+ 0 - 1
frameworks/Python/tornado/setup_py3.py

@@ -20,7 +20,6 @@ def stop(logfile, errfile):
     subprocess.call(
         'pkill -f server.py',
         shell=True, stderr=errfile, stdout=logfile)
-    time.sleep(1)
 
 
 if __name__ == '__main__':

+ 0 - 1
frameworks/Python/uwsgi/setup.py

@@ -1,7 +1,6 @@
 import multiprocessing
 import subprocess
 import os
-import time
 
 uwsgi = os.path.expandvars('$PY2_ROOT/bin/uwsgi')
 PROCS = multiprocessing.cpu_count()