Open riiiiiiki opened 1 year ago
Just use the --load-extension=
option to load a unpacked extension like:
import undetected_chromedriver as uc
import pathlib
options.add_argument(f"--load-extension="+",".join([
str(pathlib.Path("./captcha").absolute()),
str(pathlib.Path("./metamask").absolute())
]))
unpack the extensions here: https://www.ezyzip.com/open-extract-crx-file.html
Hi, @Ansh-Fakesum.
Do you have a solution on how to prevent the extension page from opening? I wouldn't want to open the metamask page like there:
Thanks! It will be helpful for me
prefs = {
"extensions.ui.developer_mode": True,
}
options.add_experimental_option("prefs", prefs)
Ok, I got it :D
Chỉ cần sử dụng
--load-extension=
tùy chọn để tải tiện ích mở rộng đã giải nén như:import undetected_chromedriver as uc import pathlib options.add_argument(f"--load-extension="+",".join([ str(pathlib.Path("./captcha").absolute()), str(pathlib.Path("./metamask").absolute()) ]))
giải nén các tiện ích mở rộng tại đây: https://www.ezyzip.com/open-extract-crx-file.html
Hi, I have successfully installed the add-on. but I have a problem that I can't open the settings page Capcha extension (metamask is still working properly). Can u help me (extension 2Capcha)
Chỉ cần sử dụng
--load-extension=
tùy chọn để tải tiện ích mở rộng đã giải nén như:import undetected_chromedriver as uc import pathlib options.add_argument(f"--load-extension="+",".join([ str(pathlib.Path("./captcha").absolute()), str(pathlib.Path("./metamask").absolute()) ]))
giải nén các tiện ích mở rộng tại đây: https://www.ezyzip.com/open-extract-crx-file.html
Hi, I have successfully installed the add-on. but I have a problem that I can't open the settings page Capcha extension (metamask is still working properly). Can u help me (extension 2Capcha)
it's silly that i put the wrong path ^^ extension's id has been changed
you should get the chrome ids from the chrome://extensions
page since the id when loaded unpacked does not stay contant for each device you use it on.
you should get the chrome ids from the
chrome://extensions
page since the id when loaded unpacked does not stay contant for each device you use it on.
can you teach me, pls Most of the documentation I've found is a guide to adding extensions to chrome. not talking about getting the extension id using selenium
you should get the chrome ids from the
chrome://extensions
page since the id when loaded unpacked does not stay contant for each device you use it on.
Hi. im trying to enable developer mode but it does not work. what am i wrong at?
Please send the exception you are getting? the image cuts off before showing full traceback. there should be no need to enable devloper mode since you can get extension id from this one line: extension_id = driver.execute_script("""return document.querySelector("body > extensions-manager").shadowRoot.querySelector("#items-list").shadowRoot.querySelectorAll("extensions-item")[{placement}].id""")
where placement is the index of the extension in chrome://extension page. this is always the same and sorted by name.
extension_id = driver.execute_script("""return document.querySelector("body > extensions-manager").shadowRoot.querySelector("#items-list").shadowRoot.querySelectorAll("extensions-item")[{placement}].id""")
This knowledge is starting to be more complicated than I imagined. This is not my area of expertise ^^ . I'm trying to learn on my own. I am so grateful for your teaching
Just add extension manually in user_data_dir and load that data_dir in uc.Chrome object
Hi! I can't add extensions crx file. Chrome always open but no extensions. did i do wrong somewhere? my code: