-
Notifications
You must be signed in to change notification settings - Fork 325
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
"The active test run was aborted. Reason: Test host process crashed" with no further explanation #4376
Comments
We've started getting this since around 6th april 10:30 GMT, across unrelated topic branches so appears not due to a change we've made. We use dotnet install scripts Edit: Could this be related a change in .NET sdk 7.0.104 somehow reaching us around this time? Edit2: No, I can't see any differences in the sdk, runtime or install-scripts.sh versions that got pulled between passing and failing builds. Will try disabling running in seperate process so I can see the actual error hopefully. |
You can add You can also add --blame-crash to see if that crash will produce a memory dump, and then analyze that with |
Right after updating SDK 6 to 6.0.311 (the latest), I'm getting a very similar error when testing unrelated branches/old commits that previously ran fine. So I have a strong suspicion it may be a recent change incorporated into multiple parallel SDK versions.
|
Full disclosure: The test host was being terminated due to out of memory (oomkiller probabbly). No idea why this suddenly started happening unless there's been a sudden change to the GC; but also made sure versions are pinned to same as when everything was passing, and the issue persists. So this one might be on us. Edit: it came back in tests that I really really doubt are OOM. Edit2: I shouldn't have doubted - they were OOM. |
I'm having exactly the same issue running in a BitBucket pipe line with: |
Mainly to support the investigation of weird crashes of test runners on MacOS environments. --- On MacOS, `dotnet test` often crashed with an output like this: -------------- The active test run was aborted. Reason: Test host process crashed : # # Fatal error in , line 0 # Check failed: 12 == (*__error()). # # # #FailureMessage Object: 0x7000099fac00 Results File: /Users/runner/work/elm-time/elm-time/implement/test-elm-time/TestResults/_Mac-1684933830638_2023-05-24_13_11_43.trx Test Run Aborted with error System.Exception: One or more errors occurred. Passed! - Failed: 0, Passed: 4, Skipped: 0, Total: 4, Duration: 4 s - test-elm-time.dll (net7.0) ---> System.Exception: Unable to read beyond the end of the stream. at System.IO.BinaryReader.Read7BitEncodedInt() at System.IO.BinaryReader.ReadString() at Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.LengthPrefixCommunicationChannel.NotifyDataAvailable() at Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.TcpClientExtensions.MessageLoopAsync(TcpClient client, ICommunicationChannel channel, Action`1 errorHandler, CancellationToken cancellationToken) --- End of inner exception stack trace ---. Error: Process completed with exit code 1. ------------ See microsoft/vstest#4376 and microsoft/vstest#2952
I had very similar issue to this one. Changing method signature to |
Likely dupe of Super frustrating that the vstest team does not seem to think the lack of diagnosabiliy here is a priority. I've wasted hours and hours on this. |
Closing as duplicate of the above issue. |
Description
This test run calls
dotnet test
, which then outputsLooking at the referenced results file (here), there is no indication of anything going wrong.
How can I get a clue of what caused the test host process to crash? Are there particular exceptions that would cause it to crash in this way such as out of memory or stack overflows?
Steps to reproduce
I don't have a small reproduction example, but this issue occurs when the CI for this PR is run
Expected behavior
I expect some sort of stack trace or explanation of why the test host process crashed, that doesn't point to from the test host process such as
Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.TcpClientExtensions.MessageLoopAsync
Actual behavior
No explanation is given
Diagnostic logs
Environment
Occurs on Ubuntu
The text was updated successfully, but these errors were encountered: