-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: issue with missing chrome browser instance during tests #26817
Conversation
pearsoj seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
|
30 flaky tests on run #46619 ↗︎
Details:
create-from-component.cy.ts • 2 flaky tests • app-e2e
specs_list_latest_runs.cy.ts • 1 flaky test • app-e2e
cypress-in-cypress-component.cy.ts • 1 flaky test • app-e2e
e2e/origin/cookie_login.cy.ts • 1 flaky test • 5x-driver-electron
commands/net_stubbing.cy.ts • 1 flaky test • 5x-driver-electron
The first 5 flaky specs are shown, see all 18 specs in Cypress Cloud. This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. |
@jazpearson please make sure to sign the CLA linked in the comment above. We cannot consider PRs that do not have that signed. |
// create a new instance of the client in case something went wrong | ||
// https://github.com/cypress-io/cypress/issues/24650 | ||
const port = await protocol.getRemoteDebuggingPort() | ||
browserCriClient = await BrowserCriClient.create(['127.0.0.1'], port, browser.displayName, options.onError, onReconnect) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since we use the same connection logic elsewhere I wonder if we can refactor this. @ryanthemanuel is this something we should be doing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking the same. I kind of wanted to get some discussion on this so we could try and attempt to fix this issue which is causing us some major head-aches. I'm more than happy to contribute towards the fix if need be.
I might have to re-make the PR as i've pushed the change logged in as my work account, and pushed to my personal github. |
Additional details
Attempts to resolve an issue with cypress that is crippling our tests runs where chrome seems to crash intermittently. This re-creates the chrome instance if it's unexpectedly null. It's a workaround, but nobody seems to know why the instance is null so trying to be pragmatic about it. Also wondering if it's worth trying an experimental feature? Either way - i wanted to see if there was a way we can get this issue fixed.
Steps to test
Really difficult to reproduce, but our cypress tests fail rouhgly 50% of the time now, even with parallelisation.
How has the user experience changed?
PR Tasks
cypress-documentation
?type definitions
?