Code Coverage collection Fails with "System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host.."
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện lệnh dotnet test được cung cấp với tính năng thu thập độ bao phủ mã được bật, sau đó kiểm tra các luồng giao tiếp và thu thập dữ liệu được nêu trong stack trace, đặc biệt là SocketCommunicationManager và DataCollectionRequestSender. Công việc được coi là hoàn tất khi các bài kiểm thử hoàn thành với tính năng thu thập độ bao phủ được bật mà không gặp ngoại lệ kết nối truyền tải.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
I am running unit tests locally on my workstation and started seeing some errors occurring with my tests. The tests all seem to pass just fine but when it seems to be collecting Code Coverage data I get a lot of the following errors
System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host..
---> System.Net.Sockets.SocketException (10054): An existing connection was forcibly closed by the remote host.
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 count)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 count)
at System.IO.BufferedStream.Flush()
at Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.SocketCommunicationManager.WriteAndFlushToChannel(String rawMessage) in /_/src/Microsoft.TestPlatform.CommunicationUtilities/SocketCommunicationManager.cs:line 413
at Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.DataCollection.DataCollectionRequestSender.SendAfterTestRunEndAndGetResult(ITestMessageEventHandler runEventsHandler, Boolean isCancelled) in /_/src/Microsoft.TestPlatform.CommunicationUtilities/DataCollectionRequestSender.cs:line 155
at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.DataCollection.ProxyDataCollectionManager.<>c__DisplayClass20_0.<AfterTestRunEnd>b__0() in /_/src/Microsoft.TestPlatform.CrossPlatEngine/DataCollection/ProxyDataCollectionManager.cs:line 155
at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.DataCollection.ProxyDataCollectionManager.InvokeDataCollectionServiceAction(Action action, ITestMessageEventHandler runEventsHandler) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/DataCollection/ProxyDataCollectionManager.cs:line 288
If I remove code coverage (essentially the --collect parameter) my tests work and complete as expected. This is using dotnet 9.0.102
dotnet test "./Framework/Framework.sln" -c Release -bl:./"Framework.Tests.binlog" --no-build --no-restore --results-directory ./TestResults --collect:"Code Coverage;Format=cobertura"
- Ngôn ngữ chính
- C#
- Star
- 125
- Fork
- 17
- Merge trung bình
- 1 giờ 17 phút
- Pull request đã merge (30 ngày)
- 2
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của microsoft/codecoverage
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
microsoft/codecoverage#246 · 6 bình luận ·
-
Forward SIGTERM to child process Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
microsoft/codecoverage#237 · 1 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
microsoft/codecoverage#234 · 1 bình luận · 2 reaction ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
microsoft/codecoverage#233 · 2 reaction ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 28/100
microsoft/codecoverage#232 · 6 bình luận ·
Tất cả issue của microsoft/codecoverage
Issue tương tự
-
bug documentation frontend
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
azurenoops/spin_agent#975 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
-
:watch: Not Triaged 11.0 fundamentals/subsvc
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 92/100
dotnet/AspNetCore.Docs#37699 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
SubtitleEdit/subtitleedit#15108 · 1 bình luận ·
-
area/docs-content Bug pulumi/docs
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 94/100