Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

How to pass argument 'user_multi_procs=True' using Driver(uc=True)? #3273

Answered by mdmintz
ZcodeZ777 asked this question in Q&A
Discussion options

I currently have a driver in python that is run with undetected-chromedriver:
driver = undetected_chromedriver.Chrome(use_subprocess=True, user_multi_procs=True, headless=True)

But I am trying to change this to a seleniumbase uc driver. How do I pass the argument 'user_multi_procs=True' into a Driver object?

You must be logged in to vote

Use the following code instead to enable safe multithreading in your files:

import sys
sys.argv.append("-n")

If multiple files, you can check to see if it's already there before adding it:

import sys
if "-n" not in sys.argv:
 sys.argv.append("-n")

Replies: 1 comment 1 reply

Comment options

Use the following code instead to enable safe multithreading in your files:

import sys
sys.argv.append("-n")

If multiple files, you can check to see if it's already there before adding it:

import sys
if "-n" not in sys.argv:
 sys.argv.append("-n")
You must be logged in to vote
1 reply
Comment options

Thanks 👍

Answer selected by mdmintz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /