Adding Chrome extension in Selenium / Python / Ubuntu
I am having problems in adding extensions in Chrome before Selenium tests, using Python.
On the code side, it's pretty simple:
options = Options() options.add_extension(/path/to/extension) webdriver.Chrome(options = options)
The problem is in finding the path. The folder where my extensions are stored is the following:
Even inside each folder I have no clue of the extension itself.
morde last edited by
Under Linux your home-dir is
So from your screenshot I would expect the path to be:
Each directory in your screenshot is an extension. You could copy the extension to a path you do know. Just copy the directory with the right ID. You can find the ID's in the Chrome extension manager. Surf too
chrome://extensions/?id=+id to check if it is the right one.