-
Notifications
You must be signed in to change notification settings - Fork 259
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
Tests fail intermittently with different exceptions #2563
Comments
You are mentioning .NET SDK 7, shall I assume that your test project is targeting .NET 7 or is it a netfx target? Would it be possible to have the diagnostic logs (VSTest) of both a working and failing build? |
All projects are targeting .NET 7. |
The best is to report issues through developercommunity, I recommend looking at https://learn.microsoft.com/cpp/overview/how-to-report-a-problem-with-the-visual-cpp-toolset?view=msvc-170#to-create-a-problem-report-for-private-information that explains well how to add private information. |
Could you make some test with our runner too? It's possible that the behavior would be different since you would not be using VSTest platform. |
Sure. Will try next week. |
Hi. I'm currently busy with other tasks and can't make the test with a new runner, but I am very interested in finding the root cause for the failures. Please keep this issue open and I hope to provide more info during the next month. |
I'm having this same issue when running test during a Docker container build, it seems to be a race condition during the assemblies instrumentation because when it's run in a single core environment it completes successfully everytime. I'm forcing the build to run in "single core" mode by limiting the number of cores available to wsl to 1 An additional exception that happens to me, at random, in addition to all of the above mentioned is:
All the projects are net 6 The versions we are using are: |
@REscobar would you mind creating a bug on coverlet repo about the exception you have mentioned? From the stack trace, I don't see anything that would be coming from our side. |
Thanks for your response, I will create the issue and mention this one on it, but as I said in my comment, I'm also experimenting the exact same issues reported above including the coverlet one becuase I just so happen to be using it, if I were to use additional instruments those would fail in strange ways too. Notice that the callstack mentions that the files are being held by another process, if there was some kind of race condition happening that would cause all of the above issues, like loading assembly files before they finish copying to the output directory would cause the loader to read incomplete metadata. |
Can you confirm your are using VSTest and not MSTest runner? |
This is the full command that I'm using |
My issue seems to be caused by coverlet, I "solved" my case by limiting the cpu count during test using |
We have an infrastructure to run integration tests with 3rd party dependencies running in k8s pods. As part of the test init process, we start different pods (MySQL, RabbitMQ, MongoDB, etc) and then run our test suits against these pods. Sometimes, the initialization process fails with strange exceptions that, I believe, obscure the real reason for failure. For example, we observed such behavior in the past when pods were killed because of OOM. Here are some examples of these exceptions
We executed tests with
--blame-crash --blame-crash-dump-type full
flags. But I wasn't able to debug the created dump. Let me know how I can send it to you if it's useful (~80MB).Additional info:
.NET SDK v7.0.313
Microsoft.NET.Test.Sdk v17.6.3
MSTest.TestAdapter v3.1.1
MSTest.TestFramework v3.1.1
The text was updated successfully, but these errors were encountered: