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

perf: remove listener to fix log memory leak #29939

Merged
merged 3 commits into from
Jul 30, 2024

Conversation

mschile
Copy link
Contributor

@mschile mschile commented Jul 30, 2024

Additional details

With protocol enabled, we add a test:after:run listener but never remove it which causes a memory leak with the log not being garbage collected. In order to fix the issue, I updated the listener to use once so it gets removed after it's called.

Steps to test

Added a test to verify the log isn't flushed multiple times.

How has the user experience changed?

PR Tasks

@jennifer-shehane
Copy link
Member

@mschile Need a changelog entry for performance

@mschile mschile changed the title fix: remove listener to fix log memory leak perf: remove listener to fix log memory leak Jul 30, 2024
@mschile
Copy link
Contributor Author

mschile commented Jul 30, 2024

@mschile Need a changelog entry for performance

Added changelog entry. ff3eca8

@jennifer-shehane jennifer-shehane removed the request for review from ryanthemanuel July 30, 2024 16:11
@jennifer-shehane jennifer-shehane merged commit dddd2d5 into develop Jul 30, 2024
73 of 83 checks passed
@jennifer-shehane jennifer-shehane deleted the mschile/protocol/log_memory_leak branch July 30, 2024 16:28
Copy link

cypress bot commented Jul 30, 2024

cypress    Run #56301

Run Properties:  status check passed Passed #56301  •  git commit ff3eca8f46: updating changelog
Project cypress
Branch Review mschile/protocol/log_memory_leak
Run ID status check passed Passed #56301
Run duration 23:08 💡
Commit git commit ff3eca8f46: updating changelog
Committer Matthew Schile
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 3
Tests that did not run due to a developer annotating a test with .skip  Pending 1328
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 29312
View all changes introduced in this branch ↗︎

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Jul 31, 2024

Released in 13.13.2.

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

@cypress-bot cypress-bot bot locked as resolved and limited conversation to collaborators Jul 31, 2024
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.

3 participants