mirror of
https://github.com/FlareSolverr/FlareSolverr.git
synced 2025-12-11 20:11:28 +01:00
Apply undetected-chromedriver patches
* Hide Chrome window in Windows/NT * Not use subprocess by default (independent process) * Kill Chromium processes properly to avoid defunct/zombie processes
This commit is contained in:
@@ -27,12 +27,14 @@ def start_detached(executable, *args):
|
||||
reader, writer = multiprocessing.Pipe(False)
|
||||
|
||||
# do not keep reference
|
||||
multiprocessing.Process(
|
||||
process = multiprocessing.Process(
|
||||
target=_start_detached,
|
||||
args=(executable, *args),
|
||||
kwargs={"writer": writer},
|
||||
daemon=True,
|
||||
).start()
|
||||
)
|
||||
process.start()
|
||||
process.join()
|
||||
# receive pid from pipe
|
||||
pid = reader.recv()
|
||||
REGISTERED.append(pid)
|
||||
|
||||
Reference in New Issue
Block a user