Error "Found invalid data while decoding".
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
Hướng nghiên cứu
The crash starts in DependencyGraphService.GenerateDependencyGraph (src/DotNetOutdated.Core/Services/DependencyGraphService.cs), called from ProjectAnalysisService.AnalyzeProject and Program.OnExecute. Reproduce with the solution from the issue, which lists a .phpproj that may not exist, and check where project entries are enumerated before the graph is loaded. Done when unsupported project types are skipped with a message and the run completes. The stack trace line numbers are from 2022 and may have shifted.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Running this command line:
dotnet-outdated "c:\myfolder\mysln.sln" -u
On that SLN:
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31815.197
MinimumVisualStudioVersion = 10.0.40219.1
Project("{A0786B88-2ADB-4C21-ABE8-AA2D79766269}") = "PhpServerComponent", "PhpServerComponent\PhpServerComponent.phpproj", "{2A8E39B9-5D74-4AD5-9021-09B376068984}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{2A8E39B9-5D74-4AD5-9021-09B376068984}.Release|Any CPU.ActiveCfg = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {3CD6D34D-D6F0-424C-9A20-A300D6018781}
EndGlobalSection
EndGlobal
Results on dotnet-outdated being crashing with:
Unhandled exception. System.IO.InvalidDataException: Found invalid data while decoding.
at NuGet.ProjectModel.DependencyGraphSpec.Load(String path)
at DotNetOutdated.Core.Services.DependencyGraphService.GenerateDependencyGraph(String projectPath) in /home/runner/work/dotnet-outdated/dotnet-outdated/src/DotNetOutdated.Core/Services/DependencyGraphService.cs:line 46
at DotNetOutdated.Core.Services.ProjectAnalysisService.AnalyzeProject(String projectPath, Boolean runRestore, Boolean includeTransitiveDependencies, Int32 transitiveDepth) in /home/runner/work/dotnet-outdated/dotnet-outdated/src/DotNetOutdated.Core/Services/ProjectAnalysisService.cs:line 28
at DotNetOutdated.Program.<OnExecute>b__78_0(String path) in /home/runner/work/dotnet-outdated/dotnet-outdated/src/DotNetOutdated/Program.cs:line 185
at System.Linq.Enumerable.SelectManySingleSelectorIterator`2.ToList()
at DotNetOutdated.Program.OnExecute(CommandLineApplication app, IConsole console) in /home/runner/work/dotnet-outdated/dotnet-outdated/src/DotNetOutdated/Program.cs:line 185
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.InvokeAsync(MethodInfo method, Object instance, Object[] arguments)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.OnExecute(ConventionContext context, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.<>c__DisplayClass0_0.<<Apply>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.ExecuteAsync(String[] args, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.Execute(String[] args)
at DotNetOutdated.Program.Main(String[] args) in /home/runner/work/dotnet-outdated/dotnet-outdated/src/DotNetOutdated/Program.cs:line 137
Please note that the solution only contains a .phpproj project reference created with DevSense.
It seems to make no difference whether the refered .phpproj file actually exists or not.
My question
Could you please make dotnet-outdated not creash in such a scenario?
I'm running dotnet-outdated from within a script that walks all SLN files in a certain folder tree and it would help me if dotnet-outdated simply ignores unexpected project types (instead of crashing).
Otherwise I probably would have to manually parse the SLN for .csproj files.
- Ngôn ngữ chính
- C#
- Star
- 1.7k
- Fork
- 172
- Merge trung bình
- 1 ngày 19 giờ
- Pull request đã merge (30 ngày)
- 39
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
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 dotnet-outdated/dotnet-outdated
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
dotnet-outdated/dotnet-outdated#871 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
dotnet-outdated/dotnet-outdated#844 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Repo is missing `.editorconfig`Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 65/100
dotnet-outdated/dotnet-outdated#677 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
dotnet-outdated/dotnet-outdated#354 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 38/100
dotnet-outdated/dotnet-outdated#845 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của dotnet-outdated/dotnet-outdated
Issue tương tự
-
triage/untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
unoplatform/uno#26676 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
.NET bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[问题] 导出文件时,提示后面还有1243390911步Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
jhaizhou-ops/S2Arm#2177 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area-CodeGen-coreclr untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
dotnet/runtime#138181 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
CO spearhead is too loudĐang mởS: Untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 2 ngày