Since very recently (3 days, at most) I noticed my Cypress process executed on GitHub Action crashes systematically. It used to work. The code changed a bit and the issue might be related to some circular reference that I'm doing now and wasn't doing before (best guess). But I've also changed the GitHub Action workflow (see https://github.com/UnlyEd/next-right-now/pull/147/files), even though nothing seems to relate to something like that.
The crash happens on a proprietary project, not the OSS project above (NRN), where it still works fine.
I wonder if building an object with circular references on the browser might be the reason behind this crash.
It'd be weird because Chrome itself works fine, also I tried running Cypress both locally and against the online url and it worked fine too.
size=47701480 seems very low for a crash, isn't that like 47Mo? Could it be related to the GitHub Action environment maybe?
Are there any information I can provide that might help?
Run cypress-io/github-action@v1
/usr/bin/docker exec 232af3f5a9948d0bb57b2f6ae7256f3ee186d24a91bee7f150b2ce4b88083f16 sh -c "cat /etc/*release | grep ^ID"
restoring cache /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
restoring cache /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Cache not found for input keys: yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db.
/bin/tar -xz -f /__w/_temp/84aa3bf8-1e87-4183-a0a4-f2352f6b7aa6/cache.tgz -C /github/home/.cache/Cypress
Cache restored from key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/yarn --frozen-lockfile
yarn install v1.22.0
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > [email protected]" has unmet peer dependency "[email protected] - 3".
warning " > [email protected]" has unmet peer dependency "popper.js@^1.16.1".
warning "react-code-blocks > [email protected]" has unmet peer dependency "react-is@>= 16.8.0".
warning "react-code-blocks > [email protected]" has incorrect peer dependency "typescript@^2.5.2 || ^3.0".
warning " > [email protected]" has unmet peer dependency "jest-runner@>= 24".
warning " > [email protected]" has unmet peer dependency "jest-docblock@>= 24".
warning " > [email protected]" has incorrect peer dependency "[email protected]".
[4/4] Building fresh packages...
Done in 81.68s.
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/npx cypress verify
25l[17:41:29] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [started]
[17:41:32] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [completed]
25h25h::debug::saving NPM modules
saving cache path /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/83f550b2-5cee-4c4c-94e5-9eb58228d4d6/cache.tgz -C /github/home/.cache/yarn .
/bin/tar: /github/home/.cache/yarn: Cannot open: No such file or directory
/bin/tar: Error is not recoverable: exiting now
Warning: The process '/bin/tar' failed with exit code 2
saving cache path /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/d86e82fa-6d19-4230-93ff-3e862de2b735/cache.tgz -C /github/home/.cache/Cypress .
Warning: Cache already exists. Scope: refs/heads/fix-gha, Key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, Version: (null)
waiting on "tfp-gem-v4-7yoxyucty.vercel.app" with timeout of 60 seconds
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Cypress test command: npx cypress run --config baseUrl=tfp-gem-v4-7yoxyucty.vercel.app --config-file cypress/config-unly-solidarity-v4.json
/usr/local/bin/npx cypress run --config baseUrl=tfp-gem-v4-7yoxyucty.vercel.app --config-file cypress/config-unly-solidarity-v4.json
Fontconfig warning: "/etc/fonts/fonts.conf", line 100: unknown element "blank"
====================================================================================================
(Run Starting)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Cypress: 5.1.0 โ
โ Browser: Electron 83 (headless) โ
โ Specs: 4 found (app/_sanity/domain.js, app/common/footer.js, app/common/nav.js, app/pages โ
โ /index.js) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/_sanity/domain.js (1 of 4)
Sanity checks > Domain
โ should be running on the right domain (3045ms)
1 passing (3s)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 3 seconds โ
โ Spec Ran: app/_sanity/domain.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/_s (1 second)
anity/domain.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/footer.js (2 of 4)
Common > Footer section
โ should have the Unly logo in the footer (2637ms)
[930:1017/174229.548039:FATAL:memory.cc(38)] Out of memory. size=47701480
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 1 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/common/footer.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/co (0 seconds)
mmon/footer.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/nav.js (3 of 4)
Common > Nav section
โ should have a link in the navbar that redirects to the home page (2550ms)
1 passing (3s)
[962:1017/174236.166001:FATAL:memory.cc(38)] Out of memory. size=47701480
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 2 seconds โ
โ Spec Ran: app/common/nav.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/co (0 seconds)
mmon/nav.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/pages/index.js (4 of 4)
0 passing (1ms)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/pages/index.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/pa (0 seconds)
ges/index.js.mp4
====================================================================================================
(Run Finished)
Spec Tests Passing Failing Pending Skipped
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ โ app/_sanity/domain.js 00:03 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/footer.js 0ms - - 1 - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/nav.js 00:02 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/pages/index.js 1ms - - - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ 1 of 4 failed (25%) 00:05 2 2 1 - -
Not crash.
No code yet.
Cypress 5.1.0
I disabled the test that was failing and the test suite passed even though the out-of-memory error happened again. ๐ค
Run cypress-io/github-action@v1
/usr/bin/docker exec 881c21907b11868385ae4f39e1fe560a4280db34f5dea48949df02d1619d5bdb sh -c "cat /etc/*release | grep ^ID"
restoring cache /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
restoring cache /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Cache not found for input keys: yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db.
/bin/tar -xz -f /__w/_temp/4699db65-1e03-4b08-b7a0-d3d0ba8c1bd1/cache.tgz -C /github/home/.cache/Cypress
Cache restored from key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/yarn --frozen-lockfile
yarn install v1.22.0
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > [email protected]" has unmet peer dependency "[email protected] - 3".
warning " > [email protected]" has unmet peer dependency "popper.js@^1.16.1".
warning "react-code-blocks > [email protected]" has unmet peer dependency "react-is@>= 16.8.0".
warning "react-code-blocks > [email protected]" has incorrect peer dependency "typescript@^2.5.2 || ^3.0".
warning " > [email protected]" has unmet peer dependency "jest-runner@>= 24".
warning " > [email protected]" has unmet peer dependency "jest-docblock@>= 24".
warning " > [email protected]" has incorrect peer dependency "[email protected]".
[4/4] Building fresh packages...
Done in 74.51s.
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/npx cypress verify
25l[18:18:33] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [started]
[18:18:35] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [completed]
25h25h::debug::saving NPM modules
saving cache path /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/5514eea2-e859-422c-9bab-794c59cde4db/cache.tgz -C /github/home/.cache/yarn .
/bin/tar: /github/home/.cache/yarn: Cannot open: No such file or directory
/bin/tar: Error is not recoverable: exiting now
Warning: The process '/bin/tar' failed with exit code 2
saving cache path /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/cf1184ab-005f-4c77-a3d5-9829c56bf357/cache.tgz -C /github/home/.cache/Cypress .
Warning: Cache already exists. Scope: refs/heads/fix-gha, Key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, Version: (null)
waiting on "tfp-gem-v4-lqxd7pl2y.vercel.app" with timeout of 60 seconds
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Cypress test command: npx cypress run --config baseUrl=tfp-gem-v4-lqxd7pl2y.vercel.app --config-file cypress/config-unly-solidarity-v4.json
/usr/local/bin/npx cypress run --config baseUrl=tfp-gem-v4-lqxd7pl2y.vercel.app --config-file cypress/config-unly-solidarity-v4.json
Fontconfig warning: "/etc/fonts/fonts.conf", line 100: unknown element "blank"
====================================================================================================
(Run Starting)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Cypress: 5.1.0 โ
โ Browser: Electron 83 (headless) โ
โ Specs: 4 found (app/_sanity/domain.js, app/common/footer.js, app/common/nav.js, app/pages โ
โ /index.js) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/_sanity/domain.js (1 of 4)
Sanity checks > Domain
โ should be running on the right domain (4500ms)
1 passing (5s)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 4 seconds โ
โ Spec Ran: app/_sanity/domain.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/_s (1 second)
anity/domain.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/footer.js (2 of 4)
0 passing (1ms)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/common/footer.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/co (0 seconds)
mmon/footer.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/nav.js (3 of 4)
Common > Nav section
โ should have a link in the navbar that redirects to the home page (4300ms)
1 passing (4s)
[957:1017/181942.453463:FATAL:memory.cc(38)] Out of memory. size=47701480
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
We detected that the Chromium Renderer process just crashed.
This is the equivalent to seeing the 'sad face' when Chrome dies.
This can happen for a number of different reasons:
- You wrote an endless loop and you must fix your own code
- There is a memory leak in Cypress (unlikely but possible)
- You are running Docker (there is an easy fix for this: see link below)
- You are running lots of tests on a memory intense application
- You are running in a memory starved VM environment
- There are problems with your GPU / GPU drivers
- There are browser bugs in Chromium
You can learn more including how to fix Docker here:
on.cypress.io/renderer-process-crashed
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 4 seconds โ
โ Spec Ran: app/common/nav.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/co (0 seconds)
mmon/nav.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/pages/index.js (4 of 4)
0 passing (4ms)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/pages/index.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/unly-solidarity-v4/app/pa (0 seconds)
ges/index.js.mp4
====================================================================================================
(Run Finished)
Spec Tests Passing Failing Pending Skipped
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ โ app/_sanity/domain.js 00:04 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/footer.js 1ms - - - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/nav.js 00:04 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/pages/index.js 1ms - - - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ All specs passed! 00:08 2 2 - - -
My intuition was right. When disabling the circular reference then Cypress doesn't run out of memory.
/usr/bin/docker exec f279a8d1c39a544d6bf681d15f75212ebfc118d7ca1b1493742544d0d8bf4107 sh -c "cat /etc/*release | grep ^ID"
restoring cache /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
restoring cache /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Cache not found for input keys: yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db.
/bin/tar -xz -f /__w/_temp/9b6b8d5f-adc2-465d-8eb5-8cc8b73d8e8c/cache.tgz -C /github/home/.cache/Cypress
Cache restored from key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/yarn --frozen-lockfile
yarn install v1.22.0
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > [email protected]" has unmet peer dependency "[email protected] - 3".
warning " > [email protected]" has unmet peer dependency "popper.js@^1.16.1".
warning "react-code-blocks > [email protected]" has unmet peer dependency "react-is@>= 16.8.0".
warning "react-code-blocks > [email protected]" has incorrect peer dependency "typescript@^2.5.2 || ^3.0".
warning " > [email protected]" has unmet peer dependency "jest-runner@>= 24".
warning " > [email protected]" has unmet peer dependency "jest-docblock@>= 24".
warning " > [email protected]" has incorrect peer dependency "[email protected]".
[4/4] Building fresh packages...
Done in 90.66s.
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
/usr/local/bin/npx cypress verify
25l[12:51:47] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [started]
[12:51:50] Verifying Cypress can run /github/home/.cache/Cypress/5.1.0/Cypress [completed]
25h25h::debug::saving NPM modules
saving cache path /github/home/.cache/yarn
primary key yarn-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/f87959c9-b151-45d3-ae8c-de7e427811f5/cache.tgz -C /github/home/.cache/yarn .
/bin/tar: /github/home/.cache/yarn: Cannot open: No such file or directory
/bin/tar: Error is not recoverable: exiting now
Warning: The process '/bin/tar' failed with exit code 2
saving cache path /github/home/.cache/Cypress
primary key cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db
/bin/tar -cz -f /__w/_temp/753a0825-9ab2-406e-ba00-70a40c0d3a86/cache.tgz -C /github/home/.cache/Cypress .
Warning: Cache already exists. Scope: refs/heads/refactor-fetch-airtable-dataset, Key: cypress-linux-x64-4f3f06b03c0eab156f16647e3ff54e9f392ae0861eff59fe6fa25fccffc1c208b8d70d4679d593444d65012c0679ab8cc123b9eaccba800c14f965bd72c362db, Version: (null)
waiting on "tfp-gem-v4-jogs7t70l.vercel.app" with timeout of 60 seconds
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Warning: The `set-env` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Cypress test command: npx cypress run --config baseUrl=tfp-gem-v4-jogs7t70l.vercel.app --config-file cypress/config-gem-v4.json
/usr/local/bin/npx cypress run --config baseUrl=tfp-gem-v4-jogs7t70l.vercel.app --config-file cypress/config-gem-v4.json
Fontconfig warning: "/etc/fonts/fonts.conf", line 100: unknown element "blank"
====================================================================================================
(Run Starting)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Cypress: 5.1.0 โ
โ Browser: Electron 83 (headless) โ
โ Specs: 4 found (app/_sanity/domain.js, app/common/footer.js, app/common/nav.js, app/pages โ
โ /index.js) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/_sanity/domain.js (1 of 4)
Sanity checks > Domain
โ should be running on the right domain (3922ms)
1 passing (4s)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 3 seconds โ
โ Spec Ran: app/_sanity/domain.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/gem-v4/app/_sanity/domain (1 second)
.js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/footer.js (2 of 4)
0 passing (0ms)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/common/footer.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/gem-v4/app/common/footer. (0 seconds)
js.mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/common/nav.js (3 of 4)
Common > Nav section
โ should have a link in the navbar that redirects to the home page (2656ms)
1 passing (3s)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 1 โ
โ Passing: 1 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 2 seconds โ
โ Spec Ran: app/common/nav.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/gem-v4/app/common/nav.js. (1 second)
mp4
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Running: app/pages/index.js (4 of 4)
0 passing (3ms)
(Results)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Tests: 0 โ
โ Passing: 0 โ
โ Failing: 0 โ
โ Pending: 0 โ
โ Skipped: 0 โ
โ Screenshots: 0 โ
โ Video: true โ
โ Duration: 0 seconds โ
โ Spec Ran: app/pages/index.js โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
(Video)
- Started processing: Compressing to 32 CRF
- Finished processing: /__w/TFP-v4/TFP-v4/cypress/videos/gem-v4/app/pages/index.js (0 seconds)
.mp4
====================================================================================================
(Run Finished)
Spec Tests Passing Failing Pending Skipped
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ โ app/_sanity/domain.js 00:03 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/footer.js 5ms - - - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/common/nav.js 00:02 1 1 - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ โ app/pages/index.js 1ms - - - - - โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ All specs passed! 00:06 2 2 - - -
Considering Cypress doesn't fail when running on my local computer, whether I'm testing a localhost server or remote server, I'd assume this has something to do with the Github Actions environment that is hosting the Cypress process.
https://docs.github.com/en/free-pro-team@latest/actions/reference/specifications-for-github-hosted-runners#supported-runners-and-hardware-resources

I enabled the code that creates a circular reference in the browser again, and the Cypress process crashed again. So, this is definitely related. This time, the memory consumption was even lower 2985948 (2Mo?):
[927:1018/130130.791498:FATAL:memory.cc(38)] Out of memory. size=2985948
I narrowed down the issue as much as I could, but did not find any way to go around it so far.
The circular reference is needed in my case, it's basically a DB model where a customer has solutions which belong to that same customer which as solutions, etc.
Circular references like this work fine in the browser though, and I expect they're not so uncommon.
I did a lot of testing and here are my findings:
consolidate script on the browser, which resolves/binds relationships together (customer.solutions[0].categories.solutions[0].categories...)consolidate script on the browser, if I don't resolve relationships within itconsolidate script on the browser, even if I only perform 1 depth resolution level (93 entities). Obviously, it crashes too if I perform a 2 depths resolution levels (783 entities)consolidate script on the server too, as soon as I parse the stringified version of it, whether it contains circular references or not. I thought the issue might come from the browser doing the work here, but it's not the case. My conclusion is that Cypress crashes when there are variables that are too big to handle. (167Ko in my case)
Also, I noticed that every page change would run the consolidate algo again, and thought that might be why Cypress would crash, because it'd eat the memory somehow. But the behaviour didn't change even when the consolidate algo is performed on the server side.
I don't understand why some tests are passing though, if Cypress crashes because of the size of the data then no test should pass at all because all pages get the same dataset.
I also don't explain it, because it was working 5 days ago with a different version of the consolidate algorithm, which was then performed by the server. (without circular references, but definitely with more than 93 loops, and was generating an output from 150ko to 12Mo, which was why I changed it in the first place)
This is very hard to debug and I spent the whole day on this. I might try to make a reproduction example if someone is willing to dig into it.
I found another cause of the crash, and it had nothing to do with the algorithm.
it('should have the customer logo in the footer', () => {
cy.get('#footer-logo').should('have.length', 1);
});
The footer logo is an <img>, and when that img is too big (132Ko in my case) then it somehow runs out of memory. When the image is 9Ko big, Cypress doesn't crash.
Eventually, the root issue is the memory. There were 2 "things" that were causing the crash here, basically the combination of the memory used by both:
consolidate algo takes up. (moving it from browser to server helped reducing the memory used)If one of them is disabled, then it doesn't reach the max memory.
If both of them are used and any of them isn't optimised then it runs out of memory.
The Cypress tests pass fine when running locally, it only happens when running on Github Actions. It is not reproducible locally, or maybe using a colossal image?
So, it's a lot of "edge case" put together that cause this. I have no idea how to improve the developer experience of this. Maybe better logs? Indicating what took what memory size? I don't know really.
Video with explanation and bug showcase: https://youtu.be/fOZyEVE4hy0
You can run Cypress in debug mode mode and get more logs. Specifically you log the memory and CPU usage of Cypress by following these instructions: https://on.cypress.io/troubleshooting#Log-memory-and-CPU-usage
You might also try disabling the Command Log (requires Cypress 5.4.0+). This can help determine if there's something rendering in the Cypress Command Log that is causing the crash.
Thanks for the documentation regarding debug mode.
I'm not quite sure how to use it from Github Actions though, I couldn't find any example at https://github.com/cypress-io/github-action.
Here is my workflow code:
# Run the E2E tests against the new Zeit deployment
- name: Run E2E tests (Cypress)
uses: cypress-io/github-action@v1 # XXX See https://github.com/cypress-io/github-action
with:
wait-on: ${{ env.ZEIT_DEPLOYMENT_URL }} # Be sure that the endpoint is ready by pinging it before starting tests, it has a timeout of 60seconds
config-file: cypress/config-${{ env.CUSTOMER_TO_DEPLOY }}.json # The config file itself doesn't matter because we will override most settings anyway. We just need `projectId` to run the tests.
config: baseUrl=${{ env.ZEIT_DEPLOYMENT_URL }} # Overriding baseUrl provided by config file to test the new deployment
# On E2E failure, upload screenshots
- name: Uplad screenshots artifacts (E2E failure)
uses: actions/upload-artifact@v1 # On failure we upload artifacts, https://help.github.com/en/actions/automating-your-workflow-with-github-actions/persisting-workflow-data-using-artifacts
if: failure()
with:
name: screenshots
path: cypress/screenshots/
# On E2E failure, upload videos
- name: Uplad videos artifacts (E2E failure)
uses: actions/upload-artifact@v1 # On failure we upload artifacts, https://help.github.com/en/actions/automating-your-workflow-with-github-actions/persisting-workflow-data-using-artifacts
if: failure()
with:
name: videos
path: cypress/videos/
How do I enable debug mode when running Run E2E tests (Cypress) action?
I assume you'd like me to run this again and add the logs with debug mode activated, so that it might be used to find the underlying issue?
Also, I noticed I'm a bit behind (Cypress 5.1 instead of 5.4, cypress-io/github-action@v1 instead of v2), does upgrading might help with out-of-memory issues?
To get debug logs, you set environment variables: DEBUG=cypress:*. Here's GitHub Action's docs on setting env vars: https://docs.github.com/en/free-pro-team@latest/actions/reference/environment-variables#about-environment-variables
I optimized my consolidate algorithm (which basically consumes 2 times less memory now) and then changed the image back to the old 134Ko and it didn't crash, which seems to confirm the theory that there is a global memory threshold that mustn't be reached or Cypress will crash.
As for "How to enable debug with Cypress on GitHub Actions", here is what I did:
# Run the E2E tests against the new Zeit deployment
- name: Run E2E tests (Cypress)
uses: cypress-io/github-action@v1 # XXX See https://github.com/cypress-io/github-action
with:
wait-on: ${{ env.ZEIT_DEPLOYMENT_URL }} # Be sure that the endpoint is ready by pinging it before starting tests, it has a timeout of 60seconds
config-file: cypress/config-${{ env.CUSTOMER_TO_DEPLOY }}.json # The config file itself doesn't matter because we will override most settings anyway. We just need `projectId` to run the tests.
config: baseUrl=${{ env.ZEIT_DEPLOYMENT_URL }} # Overriding baseUrl provided by config file to test the new deployment
env:
# Enables Cypress debugging logs, very useful if Cypress crashes, like out-of-memory issues.
# DEBUG: "cypress:*" # Enable all logs. See https://docs.cypress.io/guides/references/troubleshooting.html#Print-DEBUG-logs
DEBUG: "cypress:server:util:process_profiler" # Enable logs for "memory and CPU usage". See https://docs.cypress.io/guides/references/troubleshooting.html#Log-memory-and-CPU-usage
I will comment once I simulate another memory crash, testing with a bigger image right now.
Yeah, there is a memory threshold to running Cypress. You have to have enough resources to run the Cypress application, Chrome (running your application), ffmpeg for recording video, etc. Also Chrome can just crash from any memory leaks in the application or Cypress due to this.
Thanks for confirming.
I couldn't make Cypress crash again, even by using a 5Mo image. I believe it's a good thing in itself (I didn't understand why an image's size would affect the memory in the first place). I suppose my algorithm was what was eating most of the space, and the image size was just the tiny drop of "too much", hard to tell.
I don't know how can things be improved. Maybe it could be beneficial for developers to be taught to enable DEBUG: "cypress:server:util:process_profiler" when running into OOM issues? I don't know if the report is self-understandable for someone not familiar with Cypress, but it seems like the best step towards understanding of the underlying issue.
Most helpful comment
You can run Cypress in debug mode mode and get more logs. Specifically you log the memory and CPU usage of Cypress by following these instructions: https://on.cypress.io/troubleshooting#Log-memory-and-CPU-usage
You might also try disabling the Command Log (requires Cypress 5.4.0+). This can help determine if there's something rendering in the Cypress Command Log that is causing the crash.