Skip to content
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 font flooding #27860

Merged
merged 6 commits into from Sep 21, 2023
Merged

Conversation

ryanthemanuel
Copy link
Collaborator

@ryanthemanuel ryanthemanuel commented Sep 20, 2023

Additional details

This issue resolves a situation where needless font requests get initiated due to adding a new style tag that tries to affect scrolling globally. There are appears to be a bug in chrome where when font face fonts are retrieved via "memory cache" any changes to stylesheets causes them to be re-retrieved. This has performance impacts as it floods CDP with events and it causes unnecessary entries for Test Replay. To resolve this, we try and be more surgical with how we affect scrolling. This issue does not occur with inline styles, so instead of setting something globally, we navigate the hierarchy of the elements and set scrollBehavior to auto if the element is scrollable and has a scrollBehavior of smooth.

Steps to test

There were existing tests to validate the scrollBehavior behavior. This change should not break those.

How has the user experience changed?

n/a

PR Tasks

@cypress
Copy link

cypress bot commented Sep 20, 2023

23 flaky tests on run #51220 ↗︎

0 28134 1345 0 Flakiness 23

Details:

PR comments
Project: cypress Commit: 6e1647ccda
Status: Passed Duration: 19:15 💡
Started: Sep 21, 2023 7:29 PM Ended: Sep 21, 2023 7:48 PM
Flakiness  runs.cy.ts • 1 flaky test • app-e2e

View Output Video

Test Artifacts
App: Runs > Runs - No Runs > displays a copy button and copies correct command in Component Testing Test Replay Output Screenshots
Flakiness  top-nav.cy.ts • 1 flaky test • app-e2e

View Output Video

Test Artifacts
... > with no project id > shows "connect project" button after login if no project id is set Test Replay Output Screenshots
Flakiness  specs_list_latest_runs.cy.ts • 1 flaky test • app-e2e

View Output Video

Test Artifacts
App/Cloud Integration - Latest runs and Average duration > when no runs are recorded > shows placeholders for all visible specs Test Replay Output Screenshots
Flakiness  debug.cy.ts • 1 flaky test • app-e2e

View Output Video

Test Artifacts
App - Debug Page > shows information about a failed spec Test Replay Output Screenshots
Flakiness  cypress/cypress.cy.js • 3 flaky tests • 5x-driver-electron

View Output Video

Test Artifacts
... > correctly returns currentRetry Test Replay Output
... > correctly returns currentRetry Test Replay Output
... > correctly returns currentRetry Test Replay Output

The first 5 flaky specs are shown, see all 12 specs in Cypress Cloud.

Review all test suite changes for PR #27860 ↗︎

@ryanthemanuel ryanthemanuel merged commit ce17a44 into develop Sep 21, 2023
80 of 82 checks passed
@ryanthemanuel ryanthemanuel deleted the ryanm/fix/issue-with-font-flooding branch September 21, 2023 20:08
@cypress-bot
Copy link
Contributor

cypress-bot bot commented Sep 27, 2023

Released in 13.3.0.

This comment thread has been locked. If you are still experiencing this issue after upgrading to
Cypress v13.3.0, please open a new issue.

@cypress-bot cypress-bot bot locked as resolved and limited conversation to collaborators Sep 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants