Project introduction:
- run in python env, grpc 1.38;
- use flask frame and etcd3, flask frame use to accept the request, and use etcd3 to search the etcd datebase.
When the process problem appear:
- while the flask frame accept a request, than deal with the request, use etcd3.client to search the datebase and use subprocess.getstatusoutput to run the linux command.The project use the ProcessPoolExecutor module to avoid the process problem, all use subprocess module will be run in ProcessPoolExecutor, but I also get the same problem like this:
ImmutableMultiDict([]) !!!Error:A child process terminated abruptly, the process pool is not usable anymore
Information I have
- grpc can not use in fork maybe.
- the project use the python etcd module, but etcd use the lower python version 3.6.8, when I update the grpc module to 1.4.2, this problem can be solve, but my I worry the advanced grpc version will effect the etcd3 module.
Thanks
I do not know how to do to solve it, hope you me some suggestions, thank you.
I try to send a request to flask api, I hope it run, but in fact, when the etcd3.client module run with ProcessPoolExecutor with subprocess.getstatus module, it ProcessPoolExecutor's all child process terminated.