fix: cleanup protocol listeners - #33391
Merged
Merged
Conversation
cypress
|
||||||||||||||||||||||||||||||||||||||||
| Project |
cypress
|
| Branch Review |
mschile/protocol/cleanup
|
| Run status |
|
| Run duration | 19m 19s |
| Commit |
|
| Committer | Matthew Schile |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
10
|
|
|
1112
|
|
|
4
|
|
|
27178
|
| View all changes introduced in this branch ↗︎ | |
Warning
Partial Report: The results for the Application Quality reports may be incomplete.
UI Coverage
61.04%
|
|
|---|---|
|
|
28
|
|
|
47
|
Accessibility
99.02%
|
|
|---|---|
|
|
0 critical
3 serious
1 moderate
0 minor
|
|
|
18
|
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
ryanthemanuel
approved these changes
Feb 20, 2026
Contributor
|
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Additional details
Saw the following listeners leak:
Note
Medium Risk
Touches protocol lifecycle and CDP event wiring; mistakes could break Test Replay capture or leave listeners attached, but the changes are localized and covered by new unit tests.
Overview
Fixes capture protocol listener/resource leaks by introducing a
cleanup()lifecycle method and ensuring it runs when the protocol is re-initialized (setupProtocol), when a spec fails early (beforeSpecerror), and when the run closes (close).Updates CDP client wrapping to track wrapped listeners per event+listener and implement
off()so protocol code can reliably unregister listeners; unit tests and the test protocol fixture are updated accordingly, and the change is noted in the CLI changelog.Written by Cursor Bugbot for commit b689d38. This will update automatically on new commits. Configure here.
Steps to test
n/a
How has the user experience changed?
n/a
PR Tasks
cypress-documentation?type definitions?