OpenWPM icon indicating copy to clipboard operation
OpenWPM copied to clipboard

Disabling pop-ups lead to crash in FinalizeCommand

Open bkrumnow opened this issue 5 years ago • 0 comments

When setting pop-up block to True, each browser instances crashes during the finalizeCommand. This can be repeated by adding fo.set_preference("dom.disable_open_during_load", True) in automation/DeployBrowsers/configure_firefox.py.

https://github.com/mozilla/OpenWPM/blob/41023a800a1990e0b4177e1e345bb419d3dac222/automation/DeployBrowsers/configure_firefox.py

BrowserManager       - INFO     - BROWSER 11: EXECUTING COMMAND: IntitializeCommand()
BrowserManager       - INFO     - BROWSER 11: EXECUTING COMMAND: GetCommand(http://www.example.com,3)
BrowserManager       - INFO     - BROWSER 11: EXECUTING COMMAND: FinalizeCommand(5)
BrowserManager       - ERROR    - BROWSER 11: WebDriverException while executing command
Traceback (most recent call last):
  File ".../OpenWPM-0.12.0/automation/BrowserManager.py", line 523, in BrowserManager
    command_executor.execute_command(
  File ".../OpenWPM-0.12.0/automation/Commands/command_executor.py", line 70, in execute_command
    browser_commands.finalize(
  File ".../OpenWPM-0.12.0/automation/Commands/browser_commands.py", line 351, in finalize
    tab_restart_browser(webdriver)
  File ".../OpenWPM-0.12.0/automation/Commands/browser_commands.py", line 104, in tab_restart_browser
    assert len(webdriver.window_handles) == 1
  File ".../opt/miniconda3/envs/openwpm/lib/python3.8/site-packages/selenium/webdriver/remote/webdriver.py", line 724, in window_handles
    return self.execute(Command.W3C_GET_WINDOW_HANDLES)['value']
  File ".../opt/miniconda3/envs/openwpm/lib/python3.8/site-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute
    self.error_handler.check_response(response)
  File ".../opt/miniconda3/envs/openwpm/lib/python3.8/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.InvalidSessionIdException: Message: Tried to run command without establishing a connection

bkrumnow avatar Sep 10 '20 09:09 bkrumnow