Quantcast
Channel: Active questions tagged selenium - Stack Overflow
Viewing all articles
Browse latest Browse all 99407

Unable to launch Opera using Python Selenium

$
0
0

I am trying to launch opera using python selenium libraries. But getting capabilities error.

Codes I have tried:

Code1:

driver = webdriver.Opera()
driver.get('https://www.google.com')

Code2:

driver = webdriver.Opera(r'path to operadriver.exe')
driver.get('https://www.google.com')

Code3:

options = Options()
options.binary_location = r'C:\Opera\launcher.exe'
driver = webdriver.Opera(options=options)
driver.get('https://www.google.com')

Output:

Code1:

selenium.common.exceptions.WebDriverException: Message: unknown error: cannot find Opera binary

Code2:

selenium.common.exceptions.WebDriverException: Message: Desired Capabilities must be a dictionary

Code3:

[20904:3220:0120/034255.122:ERROR:os_crypt_win.cc(61)] Failed to decrypt: The parameter is incorrect. (0x57)

DevTools listening on ws://127.0.0.1:59016/devtools/browser/0bb7bc3c-4b9a-451a-a736-a02a63feba7a
[20904:3220:0120/034255.673:ERROR:CONSOLE(0)] "Unchecked runtime.lastError: Could not establish connection. Receiving end does not exist.", source: chrome://startpage/ (0)
[20904:3220:0120/034255.674:ERROR:CONSOLE(0)] "Unchecked runtime.lastError: Could not establish connection. Receiving end does not exist.", source: chrome://startpage/ (0)
[20904:3220:0120/034255.675:ERROR:CONSOLE(0)] "Unchecked runtime.lastError: Could not establish connection. Receiving end does not exist.", source: chrome://startpage/ (0)

Only with code 3 the Opera browser launchers. But URL doesn't opens.

As I am able to launch chrome with similar codes.


Viewing all articles
Browse latest Browse all 99407

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>