Skip to content

Ruby driver error after upgrading to 3.141.59-palladium #919

Closed

Description

@leshik

💥 Regression Report

After upgrading to the latest 3.141.59-palladium our tests are failing with

NoMethodError:
       undefined method `log' for #<Selenium::WebDriver::Remote::W3C::Bridge:0x0000555dc6fd2838>

The code in questions is page.driver.browser.manage.logs.get(:browser) (we're using Capybara).

Last working version

Worked up to version:

3.141.59-oxygen

Stopped working in version:

3.141.59-palladium

Any suggestions are appreciated. Is it related to the chromedriver? Should I file the issue there?

Activity

  1. individual-it commented on Jun 6, 2019

    @individual-it

    we are running tests with nightwatch and since the update getting

     Error while running .isElementDisplayed() protocol action: TypeError [ERR_UNESCAPED_CHARACTERS]: Error while trying to create HTTP request for "/wd/hub/session/fa970f0d7a9230b30b045d3661db484d/element/[object Object]/displayed": Request path contains unescaped characters
        at new ClientRequest (_http_client.js:115:13)
        at Object.request (http.js:42:10)
        at HttpRequest.createHttpRequest (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/http/request.js:112:55)
        at HttpRequest.send (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/http/request.js:191:29)
        at Promise (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/transport/transport.js:189:15)
        at new Promise (<anonymous>)
        at Selenium2Protocol.sendProtocolAction (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/transport/transport.js:187:12)
        at Selenium2Protocol.runProtocolAction (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/transport/jsonwire.js:61:17)
        at Object.isElementDisplayed (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/transport/actions.js:54:10)
        at Selenium2Protocol.executeProtocolAction (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/transport/transport.js:235:48)
        at WaitForElementVisible.executeProtocolAction (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/element/command.js:201:27)
        at WaitForElementVisible.protocolAction (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/api/element-commands/_waitForDisplayed.js:5:17)
        at WaitForElementVisible.elementFound (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/element/command.js:168:17)
        at action (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/api/element-commands/_waitForDisplayed.js:40:36)
        at PeriodicPromise.perform (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/util/periodic-promise.js:79:29)
        at Timeout.setTimeout (/home/artur/www/owncloud-phoenix/node_modules/nightwatch/lib/util/periodic-promise.js:117:12)
    
  2. phil-davis commented on Jun 6, 2019

    @phil-davis

    See issue #922

    It also fails with PHP Behat-Mink-Selenium stack, e.g. https://drone.owncloud.com/owncloud/core/18073/681

      Scenario: simple user login                                                                 # /drone/src/tests/acceptance/features/webUILogin/login.feature:12
        Given these users have been created with default attributes but not initialized:          # FeatureContext::theseUsersHaveBeenCreated()
          | username |
          | user1    |
        When user "user1" logs in using the webUI                                                 # WebUILoginContext::theUserLogsInUsingTheWebUI()
          Exception: Page\LoginPage::waitTillPageIsLoaded timeout waiting for page to load in /drone/src/tests/acceptance/features/lib/LoginPage.php:103
          Stack trace:
          #0 /tmp/ProxyManagerGeneratedProxy__PM__PageLoginPageGenerated6312256563dff9947346b9792a817253.php(44): Page\LoginPage->waitTillPageIsLoaded(Object(Behat\Mink\Session), 10000)
          #1 /drone/src/tests/acceptance/features/bootstrap/WebUIGeneralContext.php(226): ProxyManagerGeneratedProxy\__PM__\Page\LoginPage\Generated6312256563dff9947346b9792a817253->waitTillPageIsLoaded(Object(Behat\Mink\Session))
          #2 /drone/src/tests/acceptance/features/bootstrap/WebUILoginContext.php(152): WebUIGeneralContext->loginAs('user1', '1234')
    

    The Apache server sees the request for the login page, so a browser is starting, being sent a URL and does try to go there. But somehow the connection through selenium to chromedriver and the browser seems to just not "see" the web page (elements) that come back.

    Reverting back to selenium/standalone-chrome-debug:3.141.59-oxygen PR owncloud/core#35442 makes UI testing great again.

  3. twalpole commented on Jun 6, 2019

    @twalpole

    The initial issue reported here is because Chrome 75 defaults to W3C mode which doesn't support log access. Either specify w3c: false as an option in your driver registration or remove the code that accesses logs from your tests. The other two reports are different issues.

  4. diemol commented on Jun 6, 2019

    @diemol
    Member

    Thanks for triaging @twalpole!

  5. phil-davis commented on Jun 6, 2019

    @phil-davis

    @diemol for the other posts in this thread do we need to open a separate issue?
    #919 (comment)
    #919 (comment)

  6. diemol commented on Jun 6, 2019

    @diemol
    Member

    Yes @phil-davis, with the complete template filled out please.

  7. phil-davis commented on Jun 6, 2019

    @phil-davis

    Issue #922 raised.
    When we understand how to fix/workaround that, then I expect we will also solve @individual-it post #919 (comment)

  8. locked and limited conversation to collaborators on Aug 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions