vrepper
vrepper copied to clipboard
Not killed in Linux
After inst end, the child process is not killed. (this is weird but it only killed the vrep.sh instead of the whole thing.)
fixed by change:
def end(self):
print('(instance) terminating...')
if self.isAlive():
pid = self.inst.pid
parent = psutil.Process(pid)
for _ in parent.children(recursive=True):
_.kill()
retcode = parent.kill()
# self.inst.terminate()
# retcode = self.inst.wait()
else:
retcode = self.inst.returncode
# print('(instance) retcode:', retcode)
return self
p.s: not a neat fix, but works
issue 2: need the get_global_variable fixed in my code (my fork is not the latest since I just copied the core.py to my project.)
I'm new to open source community so I'm not so sure how this github thing works(like how to request a merge?)
after you change the code and feel satisfied with the fix:
- make a commit. now your repository of the code is newer with modifications.
- start a 'pull request', to request me to pull your commit back to my original repository.
I can then determine whether to pull your commit or not.