7 import sys |
7 import sys |
8 from os import remove, listdir, system, kill, getpgid, pathsep |
8 from os import remove, listdir, system, kill, getpgid, pathsep |
9 from os.path import exists, join, isfile, isdir |
9 from os.path import exists, join, isfile, isdir |
10 |
10 |
11 from logilab.common.clcommands import register_commands, pop_arg |
11 from logilab.common.clcommands import register_commands, pop_arg |
|
12 from logilab.common.shellutils import ASK |
12 |
13 |
13 from cubicweb import ConfigurationError, ExecutionError, BadCommandUsage, underline_title |
14 from cubicweb import ConfigurationError, ExecutionError, BadCommandUsage, underline_title |
14 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg, CONFIGURATIONS |
15 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg, CONFIGURATIONS |
15 from cubicweb.toolsutils import Command, main_run, rm, create_dir, confirm |
16 from cubicweb.toolsutils import Command, main_run, rm, create_dir |
16 |
17 |
17 def wait_process_end(pid, maxtry=10, waittime=1): |
18 def wait_process_end(pid, maxtry=10, waittime=1): |
18 """wait for a process to actually die""" |
19 """wait for a process to actually die""" |
19 import signal |
20 import signal |
20 from time import sleep |
21 from time import sleep |