MetaMask / metamask-extension

:globe_with_meridians: :electric_plug: The MetaMask browser extension enables browsing Ethereum blockchain enabled websites
https://metamask.io
Other
12.06k stars 4.93k forks source link

Fix "Test Snap Metrics tests snap install failed metric" flaky tests #26866

Closed hjetpoluru closed 2 months ago

hjetpoluru commented 2 months ago

https://app.circleci.com/pipelines/github/MetaMask/metamask-extension/98396/workflows/be9ffb55-3ba2-4b60-9a36-92a18a5f2511/jobs/3662206/tests

Test scenario - Test Snap Metrics tests snap install failed metric

Error: Unable to obtain browser driver.
        For more information on how to install drivers see
        https://www.selenium.dev/documentation/webdriver/troubleshooting/errors/driver_location/. Error: Error executing command for /home/circleci/project/node_modules/selenium-webdriver/bin/linux/selenium-manager with --browser,firefox,--output,json,--browser-path,/opt/firefox/firefox: error sending request for url (https://github.com/mozilla/geckodriver/releases/latest): error trying to connect: dns error: failed to lookup address information: Try again
  (Ran on CircleCI Node 8 of 24, Job test-e2e-firefox)
    at getPath (node_modules/selenium-webdriver/common/driverFinder.js:35:11)
    at thenableWebDriverProxy.createSession (node_modules/selenium-webdriver/firefox.js:594:45)
    at createDriver (node_modules/selenium-webdriver/index.js:152:33)
    at Builder.build (node_modules/selenium-webdriver/index.js:688:16)
    at FirefoxDriver.build (test/e2e/webdriver/firefox.js:97:28)
    at buildBrowserWebDriver (test/e2e/webdriver/index.js:41:34)
    at buildWebDriver (test/e2e/webdriver/index.js:20:13)
    at withFixtures (test/e2e/helpers.js:182:21)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Context.<anonymous> (test/e2e/snaps/test-snap-metrics.spec.js:333:5)
hjetpoluru commented 2 months ago

This is similar to this ticket and these test scenario have been successfully executed in other PR and suggesting that this failure might be an intermittent issue.

hjetpoluru commented 2 months ago

Closing this ticket as it was an intermittent issue. If it appears again it should be analyzed and retry logic should be written to fetch the geckodriver.