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

Error: ENOENT: no such file or directory #30236

Open
vj160921 opened this issue Sep 12, 2024 · 3 comments
Open

Error: ENOENT: no such file or directory #30236

vj160921 opened this issue Sep 12, 2024 · 3 comments
Labels
stage: needs information Not enough info to reproduce the issue

Comments

@vj160921
Copy link

vj160921 commented Sep 12, 2024

Current behavior

Getting this error

Error: ENOENT: no such file or directory, stat 'C:\Users\vjajula\AppData\Roaming\Cypress\cy\production\projects\TestProject-5eca4a01b3bc6b0e9c1896c350de1388\bundles\cypress\e2e\**\Testlocation\file_name.feature

after deleting the App Data. I tried running the files again but the cypress did not create app data which is maintained by cypress.

I have tried clearing cache and different workaround but that did not help.

How to restore the app data in this situation. Even I tried creating different project but the app data is not updating for the other projects as well.

Desired behavior

No response

Test code to reproduce

Deleted the app data folder from cypress and getting this error

ENOENT: no such file or directory, stat 'C:\Users\vjajula\AppData\Roaming\Cypress\cy\production\projects\TestProject-5eca4a01b3bc6b0e9c1896c350de1388\bundles\cypress\e2e\**\Testlocation\file_name.feature

Cypress Version

13.14.2

Node version

20.17.0

Operating System

Windows 11

Debug Logs

No response

Other

No response

@jennifer-shehane
Copy link
Member

@vj160921 I would have recommended clearing all App Data and cache data like you say you've done.

Could you run Cypress in debug mode mode and print the entire set of logs here?

@jennifer-shehane jennifer-shehane added the stage: needs information Not enough info to reproduce the issue label Sep 16, 2024
@GowthamiPriyanka
Copy link

HI Even my work is stuck here. I tried deleted all the Appdata and cache but after that reinstalling is giving errors.Unfortunately cant share the logs but getting similar issues

@Evilscaught
Copy link

Evilscaught commented Dec 16, 2024

@GowthamiPriyanka

I believe this issue may be related to

#19423 - Cypress not picking up most recent spec file changes

I was running into very similar errors, where the test wouldn't update when I made changes, couldn't rename the test file either - would get that same error, re-installing node_modules, clearing npm cache and cloning the repository didn't work. The cause of this bug for me was somewhere in my test I started using URLSearchParams which auto-imported from import { URLSearchParams } from 'node:url'; which caused Cypress to go nuts on me.

# Nearly identical error I was getting
Error: ENOENT: no such file or directory, stat '/Users/evilscaught/Library/Application Support/Cypress/cy/production/projects/obsidian-fe-e2e-8e9edc7003d4ce7393a3d0609d0ef9bf/bundles/src/e2e/company/accumulations-tab.cy.ts'

Given that information, have you tried replacing all the contents in your test file with the bare minimum code to see if it Cypress is able to run it?

describe('Basic test, () => {
  it('test case', () => {
     console.log('I hate node imports sometimes');
  });
});

Because if Cypress can, then it's could be something you're using, an unsupported import possibly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stage: needs information Not enough info to reproduce the issue
Projects
None yet
Development

No branches or pull requests

4 participants