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 - This issue is observing while executing await commands.measure.stop() command for second time #4192

Open
pjayaweera opened this issue Jun 19, 2024 · 8 comments

Comments

@pjayaweera
Copy link

I have site speed script to run through Jenkins pipeline and while its running i'm getting following error. This issue is getting while trying to execute the await commands.measure.stop(); command for second time (line 50).

Error: ENOENT: no such file or directory,

Login transaction is successfully completed (line 34 - line 41). During the login transaction await commands.measure.stop();(line 39) executed without any errors for the 1st time.

i have uploaded the java script file i'm running as an attachment(Test.js)
Test.txt

i have attached the pipeline script which is currently running
pipeline.txt

image image

p.s - This script is working fine in local environment.(no issues)

@soulgalore
Copy link
Member

Hi @pjayaweera in your cleanupTempFiles function don't you cleanup up data directories before the tests has ended? I think that's why the chrome driver log is removed before browsertime tries to gzip the file.

@pjayaweera
Copy link
Author

pjayaweera commented Jun 19, 2024

Hi @soulgalore, I didn't use this clean-up function initially. But faced to same issue. Then i added this clean-up function(line 43). But same result. Could you please tell me where should i call await cleanupTempFiles(); function? (just tell me the line number)

and please note error is coming while executing the line 50. So, its not reaching end of the test case.

In the attached Test.txt file you can see the full code

@soulgalore
Copy link
Member

I didn't fully get why you need to cleanup the directory inside of the script? I would move some of that functionality that do not belong to scripting (running users journey tests) to a start script that starts of the test and cleanup when the test finished.

@pjayaweera
Copy link
Author

pjayaweera commented Jun 19, 2024

I used this clean-up function as a solution given by Chat-gpt for observed issue. (Error: ENOENT: no such file or directory,)

Now i have removed the clean-up function. Below is the result.

image image

Same error is getting while coming to second transaction....

@soulgalore
Copy link
Member

Try without enabling the chrome driver log and see if it works?

@pjayaweera
Copy link
Author

pjayaweera commented Jun 19, 2024

disabled logs, but same error can see.

image image

@soulgalore
Copy link
Member

You still have --browsertime.chrome.enableChromeDriverLog in your example?

@pjayaweera
Copy link
Author

I was misunderstood initially. Your solution is worked(removing --browsertime.chrome.enableChromeDriverLog). You are genius. Thank you so much

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants