Skip to content

unknown error: unable to discover open pages #9

@Denijar

Description

@Denijar

I keep encountering this error message when I try and run in AWS Lambda:

{
  "errorMessage": "Message: 'unknown error: unable to discover open pages\\n  (Driver info: chromedriver=2.37.544315 (730aa6a5fdba159ac9f4c1e8cbc59bf1b5ce12b7),platform=Linux 4.14.165-102.205.amzn2.x86_64 x86_64)' ",
  "errorType": "WebDriverException",
  "stackTrace": [
    [
      "/var/task/src/lambda_function.py",
      35,
      "lambda_handler",
      "driver = webdriver.Chrome(chrome_options=chrome_options)"
    ],
    [
      "/var/task/lib/selenium/webdriver/chrome/webdriver.py",
      64,
      "__init__",
      "desired_capabilities=desired_capabilities)"
    ],
    [
      "/var/task/lib/selenium/webdriver/remote/webdriver.py",
      71,
      "__init__",
      "self.start_session(desired_capabilities, browser_profile)"
    ],
    [
      "/var/task/lib/selenium/webdriver/remote/webdriver.py",
      113,
      "start_session",
      "'desiredCapabilities': desired_capabilities,"
    ],
    [
      "/var/task/lib/selenium/webdriver/remote/webdriver.py",
      164,
      "execute",
      "self.error_handler.check_response(response)"
    ],
    [
      "/var/task/lib/selenium/webdriver/remote/errorhandler.py",
      164,
      "check_response",
      "raise exception_class(message, screen, stacktrace)"
    ]
  ]
}

I encounter this when using the version stack you have suggested: Python3.6, Selenium2.37, ChromeDriver2.37, Serverless Chrome v1.0.0-41.

I also encounter it when I use the version stack that has been discussed in this issue as being a compatible set of versions (Python3.6, Selenium3.14, ChromeDriver2.43, Serverless Chrome v1.0.0-55).

Some Googling has suggested that adding chrome_options.add_argument('--no-sandbox') is a fix but this has not worked for me.

Any suggestions?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions