-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
Closed
Labels
A-needs-triagingA Selenium member will evaluate this soon!A Selenium member will evaluate this soon!C-pyPython BindingsPython BindingsI-defectSomething is not working as intendedSomething is not working as intendedOS-linux
Description
Description
Calling the driver.get_log()
method when using WebKitGTK doesn't work and returns an error.
Reproducible Code
from selenium import webdriver
driver = webdriver.WebKitGTK()
print(driver.get_log('browser'))
Debugging Logs
DEBUG:selenium.webdriver.common.driver_finder:Skipping Selenium Manager; path to MiniBrowser driver specified in Service class: /usr/bin/WebKitWebDriver
DEBUG:selenium.webdriver.common.service:Started executable: `/usr/bin/WebKitWebDriver` in a child process with pid: 14632 using 0 to output -3
DEBUG:selenium.webdriver.remote.remote_connection:POST http://localhost:49185/session {'capabilities': {'firstMatch': [{}], 'alwaysMatch': {'browserName': 'MiniBrowser', 'pageLoadStrategy': <PageLoadStrategy.normal: 'normal'>, 'webkitgtk:browserOptions': {'useOverlayScrollbars': True}}}}
DEBUG:urllib3.connectionpool:Starting new HTTP connection (1): localhost:49185
DEBUG:urllib3.connectionpool:http://localhost:49185 "POST /session HTTP/1.1" 200 0
DEBUG:selenium.webdriver.remote.remote_connection:Remote response: status=200 | data={"value":{"sessionId":"db03d1ce-17cd-4f6f-9972-b721c6ae0b2a","capabilities":{"browserName":"MiniBrowser","browserVersion":"2.48","platformName":"linux","acceptInsecureCerts":false,"strictFileInteractability":false,"setWindowRect":true,"unhandledPromptBehavior":"dismiss and notify","pageLoadStrategy":"normal","proxy":{},"timeouts":{"script":30000,"pageLoad":300000,"implicit":0}}}} | headers=HTTPHeaderDict({'Server': 'WebKitWebDriver', 'Date': 'Mon, 07 Apr 2025 17:04:11 GMT', 'Content-Type': 'application/json; charset=utf-8', 'Cache-Control': 'no-cache', 'Content-Length': '382'})
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request
DEBUG:selenium.webdriver.remote.remote_connection:POST http://localhost:49185/session/db03d1ce-17cd-4f6f-9972-b721c6ae0b2a/se/log {'type': 'browser'}
DEBUG:urllib3.connectionpool:http://localhost:49185 "POST /session/db03d1ce-17cd-4f6f-9972-b721c6ae0b2a/se/log HTTP/1.1" 404 0
DEBUG:selenium.webdriver.remote.remote_connection:Remote response: status=404 | data={"value":{"error":"unknown command","message":"Unknown command: /session/db03d1ce-17cd-4f6f-9972-b721c6ae0b2a/se/log","stacktrace":""}} | headers=HTTPHeaderDict({'Server': 'WebKitWebDriver', 'Date': 'Mon, 07 Apr 2025 17:04:12 GMT', 'Content-Type': 'application/json; charset=utf-8', 'Cache-Control': 'no-cache', 'Content-Length': '135'})
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request
Traceback (most recent call last):
File "/home/cgoldberg617/code/selenium/py/sel.py", line 21, in <module>
print(driver.get_log('browser'))
~~~~~~~~~~~~~~^^^^^^^^^^^
File "/home/cgoldberg617/code/selenium/py/selenium/webdriver/remote/webdriver.py", line 1192, in get_log
return self.execute(Command.GET_LOG, {"type": log_type})["value"]
~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cgoldberg617/code/selenium/py/selenium/webdriver/remote/webdriver.py", line 429, in execute
self.error_handler.check_response(response)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
File "/home/cgoldberg617/code/selenium/py/selenium/webdriver/remote/errorhandler.py", line 232, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: Unknown command: /session/db03d1ce-17cd-4f6f-9972-b721c6ae0b2a/se/log
Metadata
Metadata
Assignees
Labels
A-needs-triagingA Selenium member will evaluate this soon!A Selenium member will evaluate this soon!C-pyPython BindingsPython BindingsI-defectSomething is not working as intendedSomething is not working as intendedOS-linux