Skip to content

[🐛 Bug]: driver.get_log() not avaliable to selenium.webdriver.remote.webdriver #15772

Open
@lozik4

Description

@lozik4

Description

After Release 4.32.0 get_log() and log_types() moved to webdriver.chromium. But if I use Remote connect I use Remote object and I can't extract logs in this case

Reproducible Code

My function    
def log_console_errors(self) -> None:
        if "chrome" in self.driver.name:
            print_error(str(type(self.driver)))
            z = self.driver.get_log("browser")
If I use local it's work ok
But if I run Remote

driver = webdriver.Remote(command_executor=f"{cfg.HUB[self.hub]}/wd/hub",
                                      client_config=ClientConfig(
                                          remote_server_addr=f"{cfg.HUB[self.hub]}/wd/hub",
                                          username=cfg.HUB_AUTH.split(":")[0],
                                          password=cfg.HUB_AUTH.split(":")[1]),
                                      options=options)

Debugging Logs

ERROR in func: log_console_errors
--------------------------------------------------------------------------------

ERROR string: <class 'selenium.webdriver.remote.webdriver.WebDriver'>

ERROR in func: pytest_runtest_makereport
--------------------------------------------------------------------------------

ERROR string: 'WebDriver' object has no attribute 'get_log'
FAILED test: TestMainBanner.test_main_banner

ℹ️ Last known working version: 4.31.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-pyPython BindingsD-chromeI-defectSomething is not working as intendedI-regressionSomething was working but we "fixed" itOS-linux

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions