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

BREAKING: add breaking changes/deprecations to cypress dependencies, … #27642

Merged

Conversation

AtofStryker
Copy link
Contributor

@AtofStryker AtofStryker commented Aug 23, 2023

…such as typescript, node, and TLS, that may affect users moving foward on v13

  • Closes N/A

Additional details

In order to get ahead of the Electron update and account for known breaking changes ahead of time, we want to remove/deprecate support for TLS, node versions, and typescript ahead of time so we don't have to publish a breaking change with the electron update, which includes an update to Node 18. These deprecations/removals include

  • Removal of Node 14 from the CLI engine. We haven't support Node 14 for a while and it isn't in our documentation for official support. This change simply makes sure users are on at least Node 16 when running Cypress
  • Deprecation of Node 16. Node 16 will be going EOL on 9/11/2023. To coincide with Node's EOL, we think its best to deprecate support of 16 moving forward. Cypress may still work with Node 16 (and likely will for 95% of users on this version even after the electron upgrade), but we do not want to guarantee support of a Node version no longer being actively maintained in 3-4 weeks.
  • The minimum supported Typescript version is 4.x to guarantee compatibility with Node 18 types. The @types/node change will take place when the electron update lands. Typescript 3.x hasn't been updated in 3 years and isn't used by many (most are on v5)
  • Pointing users to the right resolution if using TLS versions 1.0 and 1.1 and are on node 18. This is mainly due to the change in supported ciphers between Node 16 and Node 18, where TLS versions 1.0 and 1.1 require disabled ciphers. The cypress proxy server still supports these versions, but the cipher in node needs to be enabled. This can we worked around by users if they pass in --tls-cipher-list=DEFAULT@SECLEVEL=0 into their NODE_OPTIONS, such as:
    NODE_OPTIONS="--tls-cipher-list=DEFAULT@SECLEVEL=0" yarn

Steps to test

How has the user experience changed?

PR Tasks

@cypress
Copy link

cypress bot commented Aug 23, 2023

41 flaky tests on run #50417 ↗︎

0 28010 1354 0 Flakiness 41

Details:

BREAKING: add breaking changes/deprecations to cypress dependencies, such as typ...
Project: cypress Commit: 34ae9da8e4
Status: Passed Duration: 20:55 💡
Started: Aug 24, 2023 9:46 PM Ended: Aug 24, 2023 10:07 PM
Flakiness  cypress_api.cy.ts • 1 flaky test • 5x-driver-electron

View Output Video

Test Artifacts
cy.origin Cypress API > Commands > adds a custom command Test Replay Output
Flakiness  commands/traversal.cy.ts • 1 flaky test • 5x-driver-electron

View Output Video

Test Artifacts
cy.origin traversal > .children() Test Replay Output
Flakiness  commands/actions.cy.ts • 1 flaky test • 5x-driver-electron

View Output Video

Test Artifacts
cy.origin actions > .type() Test Replay Output
Flakiness  logging.cy.ts • 1 flaky test • 5x-driver-electron

View Output Video

Test Artifacts
cy.origin logging > groups callback commands on a passing test Output
Flakiness  commands/log.cy.ts • 1 flaky test • 5x-driver-electron

View Output Video

Test Artifacts
cy.origin log > logs in primary and secondary origins Test Replay Output

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

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings.

@AtofStryker
Copy link
Contributor Author

I cannot write a system test yet for the TLS error decorating, but I can add it once we update to Node 18. The only way to do that currently would be to write a system test on node 18 (since we are on 16), which isn't worth the effort. Here is a manual test of what the results would look like if a user ran into this on Node 18+

Screenshot 2023-08-24 at 12 39 11 PM
Screenshot 2023-08-24 at 12 38 58 PM

@AtofStryker AtofStryker force-pushed the breaking/remove_node14_support_deprecate_16 branch from 1814db3 to 7945637 Compare August 24, 2023 17:21
We attempted to make an http request to this URL but the request failed without a response.
// if we detect there are TLS v1/v1.1 errors, we want to direct users on
// ways they might be able to resolve their issue as the default error is cryptic
// TODO: UPDATE system-tests/test/visit_spec.js TLSv1 test to check for this error once on Electron 25 / Node 18
Copy link
Contributor Author

Choose a reason for hiding this comment

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

ill update the system test in the electron upgrade that actually checks for the printing of this message

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually, this has nothing to do with the shipped cypress node version. As lonmg as the users origin server is running a node version where they can support tls 1 or 1.1 this will be fine.

@@ -24,12 +24,6 @@ describe('e2e binary CI environments', () => {
},
)

// TODO: Where is this image located? Needs to be bumped to Node 16.16.0 or later
smokeTestDockerImage(
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We aren't sure where this image lives and is just making sure plain xvfb fails in node 12 with cypress. I don't think this test is incredibly valuable to keep around, let alone we don't know what the image is or where its maintained

Copy link
Member

Choose a reason for hiding this comment

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

@AtofStryker This image is here. Not sure if you want to update the image or remove. https://github.com/cypress-io/cypress-internal-docker-images

…such as typescript and node that may affect users moving forward on v13
@AtofStryker AtofStryker force-pushed the breaking/remove_node14_support_deprecate_16 branch from 7945637 to 34ae9da Compare August 24, 2023 21:35
Copy link
Member

@jennifer-shehane jennifer-shehane left a comment

Choose a reason for hiding this comment

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

All looks good. Thanks for investigating all the nuances @AtofStryker

@AtofStryker AtofStryker merged commit 1c6a2e1 into release/13.0.0 Aug 25, 2023
77 of 80 checks passed
@AtofStryker AtofStryker deleted the breaking/remove_node14_support_deprecate_16 branch August 25, 2023 14:10
@cypress-bot
Copy link
Contributor

cypress-bot bot commented Aug 29, 2023

Released in 13.0.0.

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

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