diff --git a/.circleci/workflows.yml b/.circleci/workflows.yml index df04d4df982a..2baee28c9b60 100644 --- a/.circleci/workflows.yml +++ b/.circleci/workflows.yml @@ -40,6 +40,7 @@ mainBuildFilters: &mainBuildFilters # use the following branch as well to ensure that v8 snapshot cache updates are fully tested - 'update-v8-snapshot-cache-on-develop' - 'ryanm/chore/add_internal_studio' + - 'electron-34' # usually we don't build Mac app - it takes a long time # but sometimes we want to really confirm we are doing the right thing @@ -50,7 +51,8 @@ macWorkflowFilters: &darwin-workflow-filters - equal: [ develop, << pipeline.git.branch >> ] # use the following branch as well to ensure that v8 snapshot cache updates are fully tested - equal: [ 'update-v8-snapshot-cache-on-develop', << pipeline.git.branch >> ] - - equal: [ 'ryanm/chore/fix-binary-due-to-proxy-from-env', << pipeline.git.branch >> ] + - equal: [ 'feat/implement_bidi', << pipeline.git.branch >> ] + - equal: [ 'electron-34', << pipeline.git.branch >> ] - matches: pattern: /^release\/\d+\.\d+\.\d+$/ value: << pipeline.git.branch >> @@ -84,7 +86,8 @@ windowsWorkflowFilters: &windows-workflow-filters - equal: [ develop, << pipeline.git.branch >> ] # use the following branch as well to ensure that v8 snapshot cache updates are fully tested - equal: [ 'update-v8-snapshot-cache-on-develop', << pipeline.git.branch >> ] - - equal: [ 'ryanm/chore/fix-binary-due-to-proxy-from-env', << pipeline.git.branch >> ] + - equal: [ 'feat/implement_bidi', << pipeline.git.branch >> ] + - equal: [ 'electron-34', << pipeline.git.branch >> ] - matches: pattern: /^release\/\d+\.\d+\.\d+$/ value: << pipeline.git.branch >> @@ -93,7 +96,7 @@ executors: # the Docker image with Cypress dependencies and Chrome browser cy-doc: docker: - - image: cypress/base-internal:20.18.1-bullseye + - image: cypress/base-internal:20.18.3-bullseye # by default, we use "medium" to balance performance + CI costs. bump or reduce on a per-job basis if needed. resource_class: medium environment: @@ -102,7 +105,7 @@ executors: kitchensink-executor: docker: - - image: cypress/base-internal:20.18.1-bullseye + - image: cypress/base-internal:20.18.3-bullseye # by default, we use "medium" to balance performance + CI costs. bump or reduce on a per-job basis if needed. resource_class: medium environment: @@ -112,7 +115,7 @@ executors: # Docker image with non-root "node" user non-root-docker-user: docker: - - image: cypress/base-internal:20.18.1-bullseye + - image: cypress/base-internal:20.18.3-bullseye user: node environment: PLATFORM: linux @@ -160,7 +163,7 @@ commands: name: Set environment variable to determine whether or not to persist artifacts command: | echo "Setting SHOULD_PERSIST_ARTIFACTS variable" - echo 'if ! [[ "$CIRCLE_BRANCH" != "develop" && "$CIRCLE_BRANCH" != "release/"* && "$CIRCLE_BRANCH" != "ryanm/chore/fix-binary-due-to-proxy-from-env" ]]; then + echo 'if ! [[ "$CIRCLE_BRANCH" != "develop" && "$CIRCLE_BRANCH" != "release/"* && "$CIRCLE_BRANCH" != "electron-34" ]]; then export SHOULD_PERSIST_ARTIFACTS=true fi' >> "$BASH_ENV" # You must run `setup_should_persist_artifacts` command and be using bash before running this command @@ -625,7 +628,7 @@ commands: apt update && apt install -y docker.io docker run -d --name better-sqlite3-builder cypress/base-internal:20.15.0-buster-python3.8-gcc-10.5 /bin/bash -c "sleep 1000000000" docker cp ~/cypress/node_modules/better-sqlite3 better-sqlite3-builder:/better-sqlite3 - docker exec -it better-sqlite3-builder /bin/bash -c "cd /better-sqlite3 && source /root/.bashrc && chown -R root:root . && npm install --ignore-scripts && npx --no-install prebuild -r electron -t 33.2.1 --include-regex 'better_sqlite3.node$'" + docker exec -it better-sqlite3-builder /bin/bash -c "cd /better-sqlite3 && source /root/.bashrc && chown -R root:root . && npm install --ignore-scripts && npx --no-install prebuild -r electron -t 34.3.3 --include-regex 'better_sqlite3.node$'" docker cp better-sqlite3-builder:/better-sqlite3/build/Release/better_sqlite3.node ~/cypress/node_modules/better-sqlite3/build/Release/better_sqlite3.node docker rm -f better-sqlite3-builder cp ~/cypress/node_modules/better-sqlite3/build/Release/better_sqlite3.node ~/cypress/better_sqlite3.node @@ -1953,7 +1956,7 @@ jobs: working_directory: ~/cypress docker: # we need an image with yarn 4 berry installed on it to run this test - - image: cypress/base-internal:20.18.1-yarn-berry + - image: cypress/base-internal:20.18.3-yarn-berry environment: # needed to inform the bootstrap-docker-container.sh script to link the binary in the system-test project directory REPO_DIR: /root/cypress @@ -1987,7 +1990,7 @@ jobs: parallelism: 1 working_directory: ~/cypress docker: - - image: cypress/base-internal:20.18.1-bullseye + - image: cypress/base-internal:20.18.3-bullseye environment: # needed to inform the bootstrap-docker-container.sh script to link the binary in the system-test project directory REPO_DIR: /root/cypress diff --git a/.github/ISSUE_TEMPLATE/1-bug-report.yml b/.github/ISSUE_TEMPLATE/1-bug-report.yml index 19d6046515e1..a6406fe80c63 100644 --- a/.github/ISSUE_TEMPLATE/1-bug-report.yml +++ b/.github/ISSUE_TEMPLATE/1-bug-report.yml @@ -43,7 +43,7 @@ body: attributes: label: Node version description: What version of node.js are you using to run Cypress? - placeholder: ex. v20.18.1 + placeholder: ex. v20.18.3 validations: required: true - type: input diff --git a/.github/ISSUE_TEMPLATE/2-memory-issue.yml b/.github/ISSUE_TEMPLATE/2-memory-issue.yml index f492fbb8d201..22cacb13f9b9 100644 --- a/.github/ISSUE_TEMPLATE/2-memory-issue.yml +++ b/.github/ISSUE_TEMPLATE/2-memory-issue.yml @@ -51,7 +51,7 @@ body: attributes: label: Node version description: What version of node.js are you using to run Cypress? - placeholder: ex. v20.18.1 + placeholder: ex. v20.18.3 validations: required: true - type: input diff --git a/.github/ISSUE_TEMPLATE/3-install-issue.yml b/.github/ISSUE_TEMPLATE/3-install-issue.yml index 2a4ce852ce3d..1301c34737bd 100644 --- a/.github/ISSUE_TEMPLATE/3-install-issue.yml +++ b/.github/ISSUE_TEMPLATE/3-install-issue.yml @@ -38,7 +38,7 @@ body: attributes: label: Node version description: What version of node.js are you using to run Cypress? - placeholder: ex. v20.18.1 + placeholder: ex. v20.18.3 validations: required: true - type: dropdown diff --git a/.node-version b/.node-version index d4b7699d36ca..87bc4c77fe13 100644 --- a/.node-version +++ b/.node-version @@ -1 +1 @@ -20.18.1 +20.18.3 diff --git a/cli/CHANGELOG.md b/cli/CHANGELOG.md index 1ba92b92fe22..8d51e397ad70 100644 --- a/cli/CHANGELOG.md +++ b/cli/CHANGELOG.md @@ -1,4 +1,14 @@ +## 14.2.1 + +_Released 3/25/2025 (PENDING)_ + +**Dependency Updates:** + +- Upgraded `electron` from `33.2.1` to `34.3.3`. Addresses [#31245](https://github.com/cypress-io/cypress/issues/31245). Addressed in [#31260](https://github.com/cypress-io/cypress/pull/31260). +- Upgraded bundled Node.js version from `20.18.1` to `20.18.3`. Addresses [#31245](https://github.com/cypress-io/cypress/issues/31245). Addressed in [#31260](https://github.com/cypress-io/cypress/pull/31260). +- Upgraded bundled Chromium version from `130.0.6723.137` to `132.0.6834.210`. Addresses [#31245](https://github.com/cypress-io/cypress/issues/31245). Addressed in [#31260](https://github.com/cypress-io/cypress/pull/31260). + ## 14.2.0 _Released 3/12/2025_ diff --git a/docker-compose.yml b/docker-compose.yml index 64f5dcbc70c1..93f156de762c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -31,7 +31,7 @@ services: - .:/opt/cypress ci: # This should mirror the image used in workflows.yml - image: cypress/base-internal:20.18.1-bullseye + image: cypress/base-internal:20.18.3-bullseye ports: - 5566:5566 - 5567:5567 diff --git a/package.json b/package.json index e71378a6e100..a9139b2a18be 100644 --- a/package.json +++ b/package.json @@ -141,7 +141,7 @@ "dedent": "^0.7.0", "del": "3.0.0", "detect-port": "^1.6.1", - "electron": "33.2.1", + "electron": "34.3.3", "electron-builder": "^25.1.8", "enzyme-adapter-react-16": "1.12.1", "eslint": "^8.56.0", @@ -214,7 +214,7 @@ "yarn-deduplicate": "3.1.0" }, "engines": { - "node": ">=20.18.1", + "node": ">=20.18.3", "yarn": ">=1.22.22" }, "productName": "Cypress", @@ -279,6 +279,7 @@ "@types/react": "18.3.12", "browserify-sign": "4.2.2", "devtools-protocol": "0.0.1413303", + "node-abi": "3.74.0", "sharp": "0.29.3", "vue-template-compiler": "2.6.12" }, diff --git a/packages/data-context/src/data/ProjectConfigIpc.ts b/packages/data-context/src/data/ProjectConfigIpc.ts index b5c4ee725677..63a18091a142 100644 --- a/packages/data-context/src/data/ProjectConfigIpc.ts +++ b/packages/data-context/src/data/ProjectConfigIpc.ts @@ -305,7 +305,8 @@ export class ProjectConfigIpc extends EventEmitter { // If they've got TypeScript installed, we can use // ts-node for CommonJS // ts-node/esm for ESM - if (hasTypeScriptInstalled(this.projectRoot)) { + // If we're in a cy in cy project, we will handle registering typescript directly in the server entry point + if (!process.env.CYPRESS_INTERNAL_E2E_TESTING_SELF_PARENT_PROJECT && hasTypeScriptInstalled(this.projectRoot)) { debug('found typescript in %s', this.projectRoot) if (isProjectUsingESModules) { debug(`using --experimental-specifier-resolution=node with --loader ${tsNodeEsm}`) diff --git a/packages/electron/README.md b/packages/electron/README.md index 208a609b2810..b83ef961ad0c 100644 --- a/packages/electron/README.md +++ b/packages/electron/README.md @@ -87,3 +87,12 @@ Upgrading `electron` involves more than just bumping this package's `package.jso *Solution*: This is often due to a mismatched prebuild of `better-sqlite3`. Ensure your repository is clear of untracked files with `git clean -xfd`, and run `yarn` again. If the issue persists, ensure you are running the latest version of your operating system. Electron prebuilds key to darwin/linux/windows, and do not differentiate between versions of the same. +#### node-abi out of date + +If you run into an error like below, please try some of the strategies below. + +```shell +Could not detect abi for version X.X.X and runtime electron. Updating "node-abi" might help solve this issue if it is a new release of electron +``` + +*Solution*: See if there's a new version of `@electron/rebuild` with a newer version of `node-abi` within it. If there is not a newer version, find the [latest release](https://github.com/electron/node-abi/releases) of `node-abi` that has an updated ABI registry with an `abi` entry matching the major version of Electron that you're updating to. Set this `node-abi` version in the `resolutions` of our [package.json](./package.json) file and rerun `yarn`. \ No newline at end of file diff --git a/scripts/binary/trigger-publish-binary-pipeline.js b/scripts/binary/trigger-publish-binary-pipeline.js index a57cfa801d6b..b7d7954d5d8c 100644 --- a/scripts/binary/trigger-publish-binary-pipeline.js +++ b/scripts/binary/trigger-publish-binary-pipeline.js @@ -16,7 +16,7 @@ const { getNextVersionForBinary } = require('../get-next-version') job_name: process.env.CIRCLE_JOB, triggered_workflow_id: process.env.CIRCLE_WORKFLOW_ID, triggered_job_url: process.env.CIRCLE_BUILD_URL, - branch: process.env.CIRCLE_BRANCH, + branch: 'electron-34', should_persist_artifacts: Boolean(process.env.SHOULD_PERSIST_ARTIFACTS), binary_version: nextVersion, }, diff --git a/system-tests/test-binary/module_api_spec.ts b/system-tests/test-binary/module_api_spec.ts index 03ac8eb60246..3200984fc4e8 100644 --- a/system-tests/test-binary/module_api_spec.ts +++ b/system-tests/test-binary/module_api_spec.ts @@ -3,7 +3,7 @@ import systemTests from '../lib/system-tests' describe('module API', () => { systemTests.it('can run module API Mocha spec', { timeout: 240000, - dockerImage: 'cypress/base-internal:20.18.1-bullseye', + dockerImage: 'cypress/base-internal:20.18.3-bullseye', withBinary: true, project: 'module-api', browser: 'electron', diff --git a/yarn.lock b/yarn.lock index 59791e8264a2..9374d3f8885a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -15035,10 +15035,10 @@ electron-to-chromium@^1.5.4: resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.13.tgz#1abf0410c5344b2b829b7247e031f02810d442e6" integrity sha512-lbBcvtIJ4J6sS4tb5TLp1b4LyfCdMkwStzXPyAgVgTRAsep4bvrAGaBOP7ZJtQMNJpSQ9SqG4brWOroNaQtm7Q== -electron@33.2.1: - version "33.2.1" - resolved "https://registry.yarnpkg.com/electron/-/electron-33.2.1.tgz#d0d7bba7a7abf4f14881d0a6e03c498b301a2d5f" - integrity sha512-SG/nmSsK9Qg1p6wAW+ZfqU+AV8cmXMTIklUL18NnOKfZLlum4ZsDoVdmmmlL39ZmeCaq27dr7CgslRPahfoVJg== +electron@34.3.3: + version "34.3.3" + resolved "https://registry.yarnpkg.com/electron/-/electron-34.3.3.tgz#2979329d182a195756bfbf6e5687a835cd65a2ec" + integrity sha512-7m1FiO1mwc1K/UqqnnkG7Ik/kAngDzmLfHwcl+xaWgCQ+Sts9rlEqzOh6g1GHhDqebrbs4bO/aU+NDi32fCciQ== dependencies: "@electron/get" "^2.0.0" "@types/node" "^20.9.0" @@ -23607,17 +23607,10 @@ nock@13.2.9: lodash "^4.17.21" propagate "^2.0.0" -node-abi@^2.7.0: - version "2.30.1" - resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-2.30.1.tgz#c437d4b1fe0e285aaf290d45b45d4d7afedac4cf" - integrity sha512-/2D0wOQPgaUWzVSVgRMx+trKJRC2UG4SUc4oCJoXx9Uxjtp0Vy3/kt7zcbxHF8+Z/pK3UloLWzBISg72brfy1w== - dependencies: - semver "^5.4.1" - -node-abi@^3.3.0, node-abi@^3.45.0: - version "3.68.0" - resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.68.0.tgz#8f37fb02ecf4f43ebe694090dcb52e0c4cc4ba25" - integrity sha512-7vbj10trelExNjFSBm5kTvZXXa7pZyKWx9RCKIyqe6I9Ev3IzGpQoqBP3a+cOdxY+pWj6VkP28n/2wWysBHD/A== +node-abi@3.74.0, node-abi@^2.7.0, node-abi@^3.3.0, node-abi@^3.45.0: + version "3.74.0" + resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-3.74.0.tgz#5bfb4424264eaeb91432d2adb9da23c63a301ed0" + integrity sha512-c5XK0MjkGBrQPGYG24GBADZud0NCbznxNx0ZkS+ebUTrmV1qTDxPxSL8zEAPURXSbLRWVexxmP4986BziahL5w== dependencies: semver "^7.3.5"