does not find cypress.config.js when using Cypress v10
When upgrading to Cypress v10 I saw this error message in CI:
You are attempting to use Cypress with an older config file: cypress.json When you upgraded to Cypress v10.0 the config file was updated and moved to a new location: cypress.config.js You may need to update any CLI scripts to ensure that they are referring the new version. This would typically look something like: "cypress open --config-file=cypress.config.js" https://on.cypress.io/migration-guide
After I added config-file: cypress.config.js the integration works.
Adding in the config-file setting for me still doesn't work:
uses: cypress-io/github-action@v2
with:
config-file: cypress.config.ts
record: true
parallel: true
group: 'UI - Chrome'
install-command: yarn --immutable
browser: chrome
headless: true
You are attempting to use Cypress with an older config file: cypress.json
When you upgraded to Cypress v10.0 the config file was updated and moved to a new location: cypress.config.ts
You may need to update any CLI scripts to ensure that they are referring the new version. This would typically look something like:
"cypress open --config-file=cypress.config.ts"
@ChillyBots update cypress-io/github-action@v2 to v4.1.0
@developer-ocansey: update cypress-io/github-action@v2 to v4.1.0
This worked for me too, and the new summary looks great! https://github.com/alxndr/almost-dead-net/actions/runs/2496531182
What's the recommended way to be notified of new versions of the action?

@alxndr, maybe watching for new releases via https://github.com/cypress-io/github-action/releases might be helpful.
@developer-ocansey thanks it works for me after change from v2 to v4.1.0
@ChillyBots update cypress-io/github-action@v2 to v4.1.0
Worked for me! Thanks @developer-ocansey :)
@ChillyBots update cypress-io/github-action@v2 to v4.1.0
thanks you're my life saver
update cypress-io/github-action@v2 to v4.1.0
silly question, how do I update this?
update cypress-io/github-action@v2 to v4.1.0
silly question, how do I update this?
Not sure how your cypress tests are set up for GitHub actions but Ideally from your project root .github > workflows > [cypress_test].yaml
You should have this line in jobs > steps
uses: cypress-io/github-action@v[4]
Here is an example of what the file looks like: https://github.com/cypress-io/github-action#basic
I had the same issue but adding this line config-file: cypress.config.ts fixed the issue and this is the code block:
- name: Run Cypress tests
uses: cypress-io/github-action@v2
with:
config-file: cypress.config.ts
working-directory: truck_mate_front
build: npm run build
start: npm start
wait-on: 'http://localhost:3000'
@medmoe
You are using an old version of the action which is not compatible with Cypress 10 and later versions:
- name: Run Cypress tests
uses: cypress-io/github-action@v2
Your workaround is unnecessary if you use the current version of the action:
- name: Run Cypress tests
uses: cypress-io/github-action@v5
v2 will be blocked from executing by GitHub at the end of May 2023. See the CHANGELOG. You should update the version of the action which you are using.
Hi @alxndr
I looked at your https://github.com/alxndr/almost-dead-net/blob/main/.github/workflows/main.yml and you are using
cypress-io/[email protected]
so although the issue here is solved, your workflow will soon fail. There is a note in the CHANGELOG which says:
Note: GitHub announced their plan to disable
save-stateandset-outputcommands by May 31, 2023. This will prevent cypress-io/github-action version v4.2.1, and earlier, running after this date since they useset-output. Affected users should update to usingv5of the cypress-io/github-action action before the deadline.
Unless you have a reason to tie your workflow to a specific minor version and patch version, then I would recommend using simply cypress-io/github-action@v5. See README > Action version.
I suggest anyway to close this issue as the original problem is resolved.
Unfortunately we have to close this issue due to inactivity. Please comment if there is new information to provide concerning the original issue and we can reopen.