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: don't inherit default message for request logging #28411

Merged
merged 8 commits into from
Nov 28, 2023

Conversation

mschile
Copy link
Contributor

@mschile mschile commented Nov 27, 2023

Additional details

During fetch/xhr request logging, we don’t set the log.message here which means when we create the message, we take the args of the current command as the message which is incorrect for a request log since it’s not related in any way to the current command.

The message of the current command can be very large at times (e.g. when the cy.task of the code-coverage plugin is running) which may have performance and memory implications both in the app and when recording for Test Replay.

Steps to test

How has the user experience changed?

PR Tasks

_Released 12/5/2023 (PENDING)_

**Bugfixes:**
- Fixed an issue where request logging would default the `message` to the `args` of the currently running command even though those `args` would not apply to the request log and are not displayed. If the `args` are sufficiently large (e.g. when running the `cy.task` from the [code-coverage](https://github.com/cypress-io/code-coverage/) plugin) there could be performance/memory implications. Addressed in [#28411](https://github.com/cypress-io/cypress/pull/28411).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a little confusing. 😅

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm open to suggestions :)

Copy link

cypress bot commented Nov 27, 2023

8 flaky tests on run #52544 ↗︎

0 554 6 0 Flakiness 8

Details:

Merge branch 'develop' into mschile/request_logging_message
Project: cypress Commit: 60d7ea6bb3
Status: Passed Duration: 13:51 💡
Started: Nov 28, 2023 2:57 PM Ended: Nov 28, 2023 3:11 PM
Flakiness  runs.cy.ts • 3 flaky tests • app-e2e

View Output

Test Artifacts
App: Runs > Runs - Create Project > when a project is created, injects new projectId into the config file, and sends expected UTM params Test Replay Screenshots
App: Runs > Runs - Cannot Find Project > opens Connect Project modal after clicking Reconnect Project button Test Replay Screenshots
... > opens the run page if a run is clicked Test Replay Screenshots
Flakiness  specs_list_e2e.cy.ts • 1 flaky test • app-e2e

View Output

Test Artifacts
... > saves the filter when navigating to a spec and back Test Replay Screenshots
Flakiness  cypress-in-cypress.cy.ts • 2 flaky tests • app-e2e

View Output

Test Artifacts
Cypress in Cypress > scales the AUT correctly in e2e Test Replay Screenshots
Cypress in Cypress > restarts browser if there is a before:browser:launch task and there is a change on the config Test Replay Screenshots
Flakiness  specs_list_latest_runs.cy.ts • 1 flaky test • app-e2e

View Output

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

View Output

Test Artifacts
App - Debug Page > shows running and updating build Test Replay Screenshots

Review all test suite changes for PR #28411 ↗︎

@mschile mschile merged commit d5678c7 into develop Nov 28, 2023
82 of 84 checks passed
@mschile mschile deleted the mschile/request_logging_message branch November 28, 2023 16:21
@cypress-bot
Copy link
Contributor

cypress-bot bot commented Dec 5, 2023

Released in 13.6.1.

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

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

4 participants