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

Build stuck with error uploading image #107

Closed
exotlv opened this issue Dec 19, 2023 · 26 comments
Closed

Build stuck with error uploading image #107

exotlv opened this issue Dec 19, 2023 · 26 comments

Comments

@exotlv
Copy link

exotlv commented Dec 19, 2023

"codeceptjs-testrail": "^1.10.5"
"codeceptjs": "^3.5.10",

When Build finished running tests - its stuck for 30min.
Stucking with such error and screenshot is not uploaded.
I tried old version 1.10.3 - works fine
image

@kobenguyent
Copy link
Owner

oh it throws the error then stuck there.

@exotlv
Copy link
Author

exotlv commented Dec 19, 2023

Yes

@kobenguyent
Copy link
Owner

https://github.com/kobenguyent/codeceptjs-testrail/blob/master/lib/testrail.js#L176 not sure why, we already catch the error.

@kobenguyent
Copy link
Owner

#108 (comment)

@exotlv
Copy link
Author

exotlv commented Dec 19, 2023

@kobenguyent I see that build is not stuck anymore.
But why screenshot stopped to upload. Cant find now but they exist in artifacts at least.
I have build 1.10.3 running for different runner and it uploads screenshots w/o a problem

@exotlv
Copy link
Author

exotlv commented Dec 19, 2023

My run: npx codeceptjs run-workers 3 --grep '@C' --reporter mochawesome --reporter-options reportDir='./output',overwrite=false

Could it be related to run-workers 3 ?
Because 1.10.3 run as single instance

@kobenguyent
Copy link
Owner

Well, my assumption is that the screenshot is not yet available at the time. You could try to use the current version with run command. I don't believe that's the issue due to new versions.

@exotlv
Copy link
Author

exotlv commented Dec 19, 2023

run-workers?

@kobenguyent
Copy link
Owner

please try https://github.com/kobenguyent/codeceptjs-testrail/releases/tag/v1.10.9.

adding the wait for file to be existed before uploading the attachment. Hope this solves the issue!

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

@kobenguyent I have now different issue type:
Plugin looking for this name of screenshot:
Error: File at Регистрация_нового_пользователя_с_валютой[email protected] doesn't exist!

But in my artifacts name is different:
image

@kobenguyent
Copy link
Owner

please try https://github.com/kobenguyent/codeceptjs-testrail/releases/tag/v1.10.10 if you have time. Many thanks!

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

Checking

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

@kobenguyent still not working:
/home/gitlab_ci_multi_runner/data/white-label/tests-ui/node_modules/codeceptjs-testrail/lib/testrail.js:197 throw Error(File at ${imageFile} doesn't exist!); ^ Error: File at Проверить_кнопку_SIGN_UP_(система_должна_вести_на_форму_регистрации)[email protected] doesn't exist! at TestRail.addAttachmentToResult (/home/gitlab_ci_multi_runner/data/white-label/tests-ui/node_modules/codeceptjs-testrail/lib/testrail.js:197:10)

I see that () was added into screenshot name

@kobenguyent
Copy link
Owner

Screenshot 2023-12-20 at 11 08 13
it worked fine for me actually.

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

For me looks like this:
image

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

@kobenguyent are you running with run-workers N or with run ?

@kobenguyent
Copy link
Owner

 npx codeceptjs run-workers 3
CodeceptJS v3.5.10 #StandWithUkraine
Running tests in 3 workers...

[01]   ✖ DEMO @C1 in 158ms
[03]   ✖ Check header color in 1724ms

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

Still getting this:
image

My runner:
npx codeceptjs run-workers 3 --grep '@C' --reporter mochawesome --reporter-options reportDir='./output',overwrite=false

@kobenguyent
Copy link
Owner

I guess the parentheses is from your test title?

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

Yes, I added it

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

What: ${screenshotPath} is used?
My screenshot names:
image

@kobenguyent
Copy link
Owner

hmm, I think you're using the unique screenshot name?

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

@kobenguyent yes

@kobenguyent
Copy link
Owner

Then I guess that is not yet supported.

@exotlv
Copy link
Author

exotlv commented Dec 20, 2023

Ok, I will remove unique screenshot names.
Now it's working!
Thank you @kobenguyent

@kobenguyent
Copy link
Owner

perfect! Glad to hear @exotlv!

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