-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
🐛 Bug: this.parent.titlePath is not a function
during parallel execution with retries
#5170
Comments
I didnt want to speculate in the OG issue (so we could delete this comment if that is against CoC), but I compared the changes from 10.4.0 to 10.6.0 and I squint my eyes when I look at this code added on 10.6.0 which seems very hard to test |
cc @sam-super @voxpelli from that PR. I believe you that this bug exists, but without a reproduction, there's really not much we can do to fix it 😞. @ReDemoNBR we'd be happy to sign an NDA if that'd help getting readonly access to your CI logs and project setup. Marking as waiting for more info in the meantime. Thanks for trying out the latest Mocha & filing! 🤎 |
Even though the project is not open source, the company is open source friendly so no NDA is needed, just your word should be enough For more info that I can give here, there are 308 test suites with 1115 tests in total. To be honest, there is not much logs in GitLab CI as the You may contact me in private using the email address in my profile |
My team has been encountering this issue. Using mocha package.json
.mocharc.json
test-file.js
command: Result:
If I switch mocha to
|
Note also #5032 (comment):
|
I see the issue, and will send a PR soon. Thanks for posting everyone! Seeing the different inputs on how this could happen was very useful. 🙂 |
this.parent.titlePath is not a function
during parallel executionthis.parent.titlePath is not a function
during parallel execution with retries
I tested #5173 (review) in my project and it worked. mocha@10.6.0 + patch from PR #5173 applied |
May update again as soon as mochajs/mocha#5170 is released.
Bug Report Checklist
faq
label, but none matched my issue.Expected
I expected to be able to run the test suites in parallel mode using
./bin/mocha --parallel <test/files>
without failure in v10.6.0Actual
The tests are failing with:
With
--full-trace
CLI option, it shows (I snipped the project name)Note that I tested this multiple times in 10.4.0 and 10.5.1 versions and I could not reproduce even after exhaustive attempts.
Minimal, Reproducible Example
I was not able to find 100% reproducible steps in my local machine, as it is not giving me consistent behavior, failing around 40% of the time in different test suites.
However in our CI environment (6 vCPU + 16GB RAM machines) it is failing at all times when using 6 parallel jobs, in different test suites.
So I could not find a specific code to trigger it
Versions
Versions:
Shell: Bash (5.2.026-5) (ArchLinux)
Related modules: JS with ESModules
Additional Info
During my own debugging of the mocha v10.6.0 directly installed in
node_modules
, I was able to add some debugging info and found that at this line,this.parent
is actually a string with value"[Circular]"
(without quotes), thus failing when trying to access the functionthis.parent.titlePath()
.I could not find the error in v10.4.0 or v10.5.1 (I did not test v10.5.0)
The text was updated successfully, but these errors were encountered: