Removed extra imported psutil and added try and except block for the psutil pid condition
This commit is contained in:
parent
080005d870
commit
f2e816d660
|
@ -58,12 +58,14 @@ class TestProcessProto(unittest.TestCase):
|
||||||
cls.process.send_signal(signal.SIGTERM)
|
cls.process.send_signal(signal.SIGTERM)
|
||||||
try:
|
try:
|
||||||
cls.process.wait(timeout)
|
cls.process.wait(timeout)
|
||||||
# import traceback
|
try:
|
||||||
print('55555555555555555')
|
print('55555555555555555')
|
||||||
import psutil
|
|
||||||
print('psutil.pid_exists(cls.process.pid)-{}'.format(
|
print('psutil.pid_exists(cls.process.pid)-{}'.format(
|
||||||
psutil.pid_exists(cls.process.pid)))
|
psutil.pid_exists(cls.process.pid)))
|
||||||
print('55555555555555555')
|
print('55555555555555555')
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
# import traceback
|
||||||
# traceback.print_stack()
|
# traceback.print_stack()
|
||||||
logger.error('_stop_process')
|
logger.error('_stop_process')
|
||||||
logger.error('this condition are getting killed are not')
|
logger.error('this condition are getting killed are not')
|
||||||
|
|
Reference in New Issue
Block a user