-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why does undetected chromedriver leave so many instances of chrome.exe open in memory? #1270
Comments
Because |
Is there any reason why this hasn't been merged into the main branch? Is there anyway I can specify a branch installing directly from pycharm? Or do I have to do dl from github and point to it manually? |
@ManiMozaffar So I'm reading conflicting information in these threads. Does your commit itself fix this issue? Do I need to include some type of implicit wait after driver.quit() as well? Thanks for the help |
This isn't merged, because in both PRs, the maintainers haven't checked and provided feedback.
no you don't need to, just use my code. |
@ManiMozaffar I'm not sure what the best solution is to this, but I think for the time being, I may have to use the os package to kill all chrome instances between each iteration of my script. I'll keep my eyes open here tho to see if any solution is found. Thanks again |
Because i will only fix cricital issues. Im rewriting the whole package. (Spoiler: this performs like crazy, and no more Chrome driver |
Interesting, thanks for the update. Any rough eta on the new package? In the meantime, I'll just use os to kill the chrome that stays open in memory |
Did anyone try to run in incognito mode? |
Whats the timeline on the new implementation? |
Unset the uc.Chrome(driver_executable_path=driver_executable_path, options=options, user_data_dir=user_data_dir, no_sandbox=False, user_multi_procs=True, use_subprocess=False) But some things to consider: |
is there any solution for quit() problem? |
Eagerly waiting for this. |
do you know if there is a development blog for this? would love to follow along and try to learn. feeling pretty useless at the moment trying to fix the old version of uc. anyway hopefully this comes out soon - looking forward to it |
Have you found a solution? |
@Sleeeepy7 |
I get this error and I use that flag. |
@cmdlinebeep This is so weird that its working on my computer and my friend and few vms putted for tests. Can you share version of undetected-chromedriver and your chrome version? |
Is there still no solution for this, I am using the pip package, is the issue fixed on this repo? |
For me and my friend adding option to disable gpu helped, but its not working for everybody options.add_argument("--disable-gpu") |
Just checking if the fix to the open socket problem is available? |
I've found using an older version of Chrome like V113 works. But V113 is also less stable than the current 124 |
I don't mind downgrading but can you confirm that the socket issue really goes away with it? I had to add a hack that reboots the service after it has 1000 open sockets. |
hello, I had the same problem about the phantom processes and I managed to solve it by using pyautogui to close the browser just before applying the driver.quit(), this way the browser is completely closed just before the driver.quit() and leaves no trace in the task manager, this solution was effective for me. I hope this helps you.
You can adjust the duration of this action to make it more instantaneous |
It's a workaround for sure but it would be nice to have a working |
For me using both driver.close() and driver.quit() one by one helped a lot |
after driver.quit() call destroyChromeProcess (code that close any chrome process that its parent pid is not exists) like this :
|
My script opens a new chrome every few minutes and exits with driver.quit(). With a normal chrome driver, driver.quit() kills everything. With undetected chrome driver, for some reason, I see each insteance of Google Chrome stay open in the task manager despite having the window disappeared from the screen. I have to end task manually in task manager or they will max out my cpu.
Does anyone know why this is happening or how to rectify?
The text was updated successfully, but these errors were encountered: