Skip to content
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

[Templates] Local build failures because of workloads #58957

Closed
javiercn opened this issue Nov 14, 2024 · 2 comments · Fixed by #59079
Closed

[Templates] Local build failures because of workloads #58957

javiercn opened this issue Nov 14, 2024 · 2 comments · Fixed by #59079
Labels
area-mvc Includes: MVC, Actions and Controllers, Localization, CORS, most templates

Comments

@javiercn
Copy link
Member

javiercn commented Nov 14, 2024

The following test was failing on the referenced PR

Templates.Mvc.Test.WebApiTemplateTest.WebApiTemplateCSharp_IdentityWeb_SingleOrg_ProgramMain_NoHttps_BuildsAndPublishes(auth: "SingleOrg", args: null) [FAIL]
Project new webapi --no-restore --auth SingleOrg failed to create. Exit code 57005.
D:\a_work\1\s\src\ProjectTemplates\test\Templates.Mvc.Tests\bin\Release\net10.0\TestTemplates\dotnet\dotnet.exe new webapi --debug:disable-sdk-templates --debug:custom-hive "D:\a_work\1\s\src\ProjectTemplates\test\Templates.Mvc.Tests\bin\Release\net10.0\TestTemplates\Hives\b55ce3d6-511a-4a05-aab3-f2edc08a0392.templateengine" --no-restore --auth SingleOrg -o D:\a_work\1\s\src\ProjectTemplates\test\Templates.Mvc.Tests\bin\Release\net10.0\TestTemplates\AspNet.ury0lgakqwsu\nStdErr: Fatal error. 0xC0000005
at Microsoft.VisualStudio.Setup.Configuration.IEnumSetupInstances.Next(Int32, Microsoft.VisualStudio.Setup.Configuration.ISetupInstance[], Int32 ByRef)
at Microsoft.DotNet.Workloads.Workload.VisualStudioWorkloads.GetVisualStudioInstances()
at Microsoft.DotNet.Workloads.Workload.VisualStudioWorkloads.GetInstalledWorkloads(Microsoft.NET.Sdk.WorkloadManifestReader.IWorkloadResolver, Microsoft.DotNet.Workloads.Workload.List.InstalledWorkloadsCollection, System.Nullable1<Microsoft.NET.Sdk.WorkloadManifestReader.SdkFeatureBand>) at Microsoft.DotNet.Workloads.Workload.List.WorkloadInfoHelper.AddInstalledVsWorkloads(System.Collections.Generic.IEnumerable1<Microsoft.NET.Sdk.WorkloadManifestReader.WorkloadId>)
at Microsoft.DotNet.Workloads.Workload.List.WorkloadInfoHelper.get_InstalledAndExtendedWorkloads()
at Microsoft.DotNet.Tools.New.WorkloadsInfoProvider.GetInstalledWorkloadsAsync(System.Threading.CancellationToken)
at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+d__9.MoveNext()
at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+d__9, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](d__9 ByRef)
at System.Runtime.CompilerServices.AsyncTaskMethodBuilder1[[System.ValueTuple2[[System.__Canon, System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.__Canon, System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+d__9, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](d__9 ByRef)
at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint.ExtractWorkloadInfoAsync(System.Collections.Generic.IEnumerable1<Microsoft.TemplateEngine.Abstractions.Components.IWorkloadsInfoProvider>, Microsoft.Extensions.Logging.ILogger, System.Threading.CancellationToken) at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+<CreateAsync>d__6.MoveNext() at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+<CreateAsync>d__6, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](<CreateAsync>d__6 ByRef) at System.Runtime.CompilerServices.AsyncTaskMethodBuilder1[[System.__Canon, System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint+d__6, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](d__6 ByRef)
at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+WorkloadConstraint.CreateAsync(Microsoft.TemplateEngine.Abstractions.IEngineEnvironmentSettings, Microsoft.TemplateEngine.Abstractions.Constraints.ITemplateConstraintFactory, System.Threading.CancellationToken)
at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+d__5.MoveNext()
at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+d__5, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](d__5 ByRef)
at System.Runtime.CompilerServices.AsyncTaskMethodBuilder1[[System.__Canon, System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Start[[Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory+<Microsoft-TemplateEngine-Abstractions-Constraints-ITemplateConstraintFactory-CreateTemplateConstraintAsync>d__5, Microsoft.TemplateEngine.Edge, Version=10.0.100.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]](<Microsoft-TemplateEngine-Abstractions-Constraints-ITemplateConstraintFactory-CreateTemplateConstraintAsync>d__5 ByRef) at Microsoft.TemplateEngine.Edge.Constraints.WorkloadConstraintFactory.Microsoft.TemplateEngine.Abstractions.Constraints.ITemplateConstraintFactory.CreateTemplateConstraintAsync(Microsoft.TemplateEngine.Abstractions.IEngineEnvironmentSettings, System.Threading.CancellationToken) at System.Threading.Tasks.Task1[[System.__Canon, System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].InnerInvoke()
at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(System.Threading.Thread, System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef, System.Threading.Thread)
at System.Threading.ThreadPoolWorkQueue.Dispatch()
at System.Threading.PortableThreadPool+WorkerThread.WorkerThreadStart()
\nStdOut: [createdump] Writing minidump with heap for process 1724 to file D:\a_work\1\s/dotnet-1724.1731515615.core
[createdump] Dump successfully written in 185ms

  Stack Trace:
       at Templates.Test.Helpers.Project.RunDotNetNewAsync(String templateName, String auth, String language, Boolean useLocalDB, Boolean noHttps, Boolean errorOnRestoreError, Boolean isItemTemplate, String[] args, IDictionary`2 environmentVariables)
    D:\a\_work\1\s\src\ProjectTemplates\test\Templates.Mvc.Tests\WebApiTemplateTest.cs(218,0): at Templates.Mvc.Test.WebApiTemplateTest.PublishAndBuildWebApiTemplate(String languageOverride, String auth, String[] args)
    --- End of stack trace from previous location ---

The remaining error seems unrelated

_Originally posted by @javiercn in https://github.com/dotnet/aspnetcore/issues/58862#issuecomment-2474578237_
            
@dotnet-issue-labeler dotnet-issue-labeler bot added the area-mvc Includes: MVC, Actions and Controllers, Localization, CORS, most templates label Nov 14, 2024
@BrennanConroy
Copy link
Member

Same as dotnet/sdk#44878

@wtgodbe
Copy link
Member

wtgodbe commented Nov 18, 2024

As far as I can tell, this failure only occurs in the Windows.Amd64.VS2022.Pre.Open queue (in Helix) and on the windows.vs2022preview.amd64.open build image (Windows local dev job). Haven't yet found a failure on the Win11 queue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-mvc Includes: MVC, Actions and Controllers, Localization, CORS, most templates
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants