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

[Infrastructure] Unblock installer #55358

Merged
merged 5 commits into from
Apr 25, 2024
Merged

Conversation

javiercn
Copy link
Member

@javiercn javiercn commented Apr 25, 2024

Split some changes from
#55339
To unblock
dotnet/installer#19577

@dotnet-issue-labeler dotnet-issue-labeler bot added the area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions label Apr 25, 2024
@kasperk81
Copy link
Contributor

null-conditional operator ?[] is a correct replacement for FirstOrDefault

@javiercn
Copy link
Member Author

null-conditional operator ?[] is a correct replacement for FirstOrDefault

image

@kasperk81
Copy link
Contributor

nvm, i was read it wrong

@tannergooding
Copy link
Member

Commented here as well: dotnet/installer#19577 (comment), but the simpler fix here is to put CA1826.severity (

# CA1826: Do not use Enumerable methods on indexable collections. Instead use the collection directly
) back to its default, which is suggestion.

The linked comment has some context about the intent of the analyzer and why it can potentially be viewed as deprecated moving forward.

@tannergooding
Copy link
Member

Does this PR need to also handle

error MSB4018: (NETCORE_ENGINEERING_TELEMETRY=Build) The "RepoTasks.RemoveSharedFrameworkDependencies" task failed unexpectedly.
System.MissingMethodException: Method not found: 'Boolean System.Collections.Generic.ISet1.Contains(!0)'. at RepoTasks.RemoveSharedFrameworkDependencies.FilterDependencies(String targetPath, ISet1 dependencyToRemove)
at RepoTasks.RemoveSharedFrameworkDependencies.Execute() in /_/src/aspnetcore/eng/tools/RepoTasks/RemoveSharedFrameworkDependencies.cs:line 38
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)

Which is also occurring in the blocked installer build: https://github.com/dotnet/installer/pull/19577/checks?check_run_id=24250325560

From the other PR, it sounds like this is due to project not use the shared framework workaround and so its compiling against an out of date BCL?

@javiercn
Copy link
Member Author

Does this PR need to also handle

error MSB4018: (NETCORE_ENGINEERING_TELEMETRY=Build) The "RepoTasks.RemoveSharedFrameworkDependencies" task failed unexpectedly.
System.MissingMethodException: Method not found: 'Boolean System.Collections.Generic.ISet1.Contains(!0)'. at RepoTasks.RemoveSharedFrameworkDependencies.FilterDependencies(String targetPath, ISet1 dependencyToRemove)
at RepoTasks.RemoveSharedFrameworkDependencies.Execute() in /_/src/aspnetcore/eng/tools/RepoTasks/RemoveSharedFrameworkDependencies.cs:line 38
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)

Which is also occurring in the blocked installer build: https://github.com/dotnet/installer/pull/19577/checks?check_run_id=24250325560

From the other PR, it sounds like this is due to project not use the shared framework workaround and so its compiling against an out of date BCL?

I'm not sure, @wtgodbe will know best.

@javiercn
Copy link
Member Author

I've created a separate PR #55361 to change the rule to suggestion

@javiercn javiercn marked this pull request as ready for review April 25, 2024 14:43
@javiercn
Copy link
Member Author

Does this PR need to also handle

error MSB4018: (NETCORE_ENGINEERING_TELEMETRY=Build) The "RepoTasks.RemoveSharedFrameworkDependencies" task failed unexpectedly.
System.MissingMethodException: Method not found: 'Boolean System.Collections.Generic.ISet1.Contains(!0)'. at RepoTasks.RemoveSharedFrameworkDependencies.FilterDependencies(String targetPath, ISet1 dependencyToRemove)
at RepoTasks.RemoveSharedFrameworkDependencies.Execute() in /_/src/aspnetcore/eng/tools/RepoTasks/RemoveSharedFrameworkDependencies.cs:line 38
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)

Which is also occurring in the blocked installer build: https://github.com/dotnet/installer/pull/19577/checks?check_run_id=24250325560

From the other PR, it sounds like this is due to project not use the shared framework workaround and so its compiling against an out of date BCL?

I think you are right, we also need a change with the build infrastructure change. I'm not familiar with that area so I think we'll need @wtgodbe for that. I'm not sure if we can separate that change into its own change that runs with the current SDK so that we can merge it and make things flow, get a new installer and then update other PRs with it.

@wtgodbe
Copy link
Member

wtgodbe commented Apr 25, 2024

Here's a hacky workaround to fix the RepoTasks issue: https://github.com/dotnet/aspnetcore/pull/55339/files#diff-c86671b0d4350666f7a867a36dd59de3723a6c8288eed724bc6dc2dac3a37990L67

The runtime dependency update is blocked by some test failures and other issues, so we should just port the above to here to unblock installer

@javiercn javiercn requested review from wtgodbe and a team as code owners April 25, 2024 15:15
@javiercn
Copy link
Member Author

@wtgodbe I've applied your suggestion here

@javiercn javiercn enabled auto-merge (squash) April 25, 2024 15:17
@javiercn javiercn merged commit 8951d73 into main Apr 25, 2024
26 checks passed
@javiercn javiercn deleted the javiercn/unblock-installer-04-25-2024 branch April 25, 2024 17:12
@dotnet-policy-service dotnet-policy-service bot added this to the 9.0-preview5 milestone Apr 25, 2024
wtgodbe pushed a commit that referenced this pull request Apr 29, 2024
* Fixes to analyzers and build infrastructure.
wtgodbe pushed a commit that referenced this pull request May 1, 2024
…/runtime (#55372)

* Update dependencies from https://github.com/dotnet/runtime build 20240425.7

Microsoft.Bcl.AsyncInterfaces , Microsoft.Bcl.TimeProvider , Microsoft.Extensions.Caching.Abstractions , Microsoft.Extensions.Caching.Memory , Microsoft.Extensions.Configuration , Microsoft.Extensions.Configuration.Abstractions , Microsoft.Extensions.Configuration.Binder , Microsoft.Extensions.Configuration.CommandLine , Microsoft.Extensions.Configuration.EnvironmentVariables , Microsoft.Extensions.Configuration.FileExtensions , Microsoft.Extensions.Configuration.Ini , Microsoft.Extensions.Configuration.Json , Microsoft.Extensions.Configuration.UserSecrets , Microsoft.Extensions.Configuration.Xml , Microsoft.Extensions.DependencyInjection , Microsoft.Extensions.DependencyInjection.Abstractions , Microsoft.Extensions.DependencyModel , Microsoft.Extensions.Diagnostics , Microsoft.Extensions.Diagnostics.Abstractions , Microsoft.Extensions.FileProviders.Abstractions , Microsoft.Extensions.FileProviders.Composite , Microsoft.Extensions.FileProviders.Physical , Microsoft.Extensions.FileSystemGlobbing , Microsoft.Extensions.HostFactoryResolver.Sources , Microsoft.Extensions.Hosting , Microsoft.Extensions.Hosting.Abstractions , Microsoft.Extensions.Http , Microsoft.Extensions.Logging , Microsoft.Extensions.Logging.Abstractions , Microsoft.Extensions.Logging.Configuration , Microsoft.Extensions.Logging.Console , Microsoft.Extensions.Logging.Debug , Microsoft.Extensions.Logging.EventLog , Microsoft.Extensions.Logging.EventSource , Microsoft.Extensions.Logging.TraceSource , Microsoft.Extensions.Options , Microsoft.Extensions.Options.ConfigurationExtensions , Microsoft.Extensions.Options.DataAnnotations , Microsoft.Extensions.Primitives , Microsoft.Internal.Runtime.AspNetCore.Transport , Microsoft.NET.Runtime.MonoAOTCompiler.Task , Microsoft.NET.Runtime.WebAssembly.Sdk , Microsoft.NETCore.App.Ref , Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.browser-wasm , Microsoft.NETCore.App.Runtime.win-x64 , Microsoft.NETCore.BrowserDebugHost.Transport , Microsoft.NETCore.Platforms , System.Collections.Immutable , System.Composition , System.Configuration.ConfigurationManager , System.Diagnostics.DiagnosticSource , System.Diagnostics.EventLog , System.Diagnostics.PerformanceCounter , System.DirectoryServices.Protocols , System.IO.Hashing , System.IO.Pipelines , System.Net.Http.Json , System.Net.Http.WinHttpHandler , System.Reflection.Metadata , System.Resources.Extensions , System.Runtime.Caching , System.Security.Cryptography.Pkcs , System.Security.Cryptography.Xml , System.Security.Permissions , System.ServiceProcess.ServiceController , System.Text.Encodings.Web , System.Text.Json , System.Threading.AccessControl , System.Threading.Channels , System.Threading.RateLimiting , Microsoft.SourceBuild.Intermediate.runtime.linux-x64
 From Version 9.0.0-preview.4.24222.10 -> To Version 9.0.0-preview.4.24225.7

* Update dependencies from https://github.com/dotnet/efcore build 20240426.1

dotnet-ef , Microsoft.EntityFrameworkCore , Microsoft.EntityFrameworkCore.Design , Microsoft.EntityFrameworkCore.InMemory , Microsoft.EntityFrameworkCore.Relational , Microsoft.EntityFrameworkCore.Sqlite , Microsoft.EntityFrameworkCore.SqlServer , Microsoft.EntityFrameworkCore.Tools
 From Version 9.0.0-preview.5.24223.1 -> To Version 9.0.0-preview.4.24226.1

* Update the severity of CA1826 to suggestion

Update the severity of CA1826 to suggestion as it's not really applicable in modern TFMs (#55361)

* [Infrastructure] Unblock installer (#55358)

* Fixes to analyzers and build infrastructure.

* Update dependencies from https://github.com/dotnet/runtime build 20240427.4

Microsoft.Bcl.AsyncInterfaces , Microsoft.Bcl.TimeProvider , Microsoft.Extensions.Caching.Abstractions , Microsoft.Extensions.Caching.Memory , Microsoft.Extensions.Configuration , Microsoft.Extensions.Configuration.Abstractions , Microsoft.Extensions.Configuration.Binder , Microsoft.Extensions.Configuration.CommandLine , Microsoft.Extensions.Configuration.EnvironmentVariables , Microsoft.Extensions.Configuration.FileExtensions , Microsoft.Extensions.Configuration.Ini , Microsoft.Extensions.Configuration.Json , Microsoft.Extensions.Configuration.UserSecrets , Microsoft.Extensions.Configuration.Xml , Microsoft.Extensions.DependencyInjection , Microsoft.Extensions.DependencyInjection.Abstractions , Microsoft.Extensions.DependencyModel , Microsoft.Extensions.Diagnostics , Microsoft.Extensions.Diagnostics.Abstractions , Microsoft.Extensions.FileProviders.Abstractions , Microsoft.Extensions.FileProviders.Composite , Microsoft.Extensions.FileProviders.Physical , Microsoft.Extensions.FileSystemGlobbing , Microsoft.Extensions.HostFactoryResolver.Sources , Microsoft.Extensions.Hosting , Microsoft.Extensions.Hosting.Abstractions , Microsoft.Extensions.Http , Microsoft.Extensions.Logging , Microsoft.Extensions.Logging.Abstractions , Microsoft.Extensions.Logging.Configuration , Microsoft.Extensions.Logging.Console , Microsoft.Extensions.Logging.Debug , Microsoft.Extensions.Logging.EventLog , Microsoft.Extensions.Logging.EventSource , Microsoft.Extensions.Logging.TraceSource , Microsoft.Extensions.Options , Microsoft.Extensions.Options.ConfigurationExtensions , Microsoft.Extensions.Options.DataAnnotations , Microsoft.Extensions.Primitives , Microsoft.Internal.Runtime.AspNetCore.Transport , Microsoft.NET.Runtime.MonoAOTCompiler.Task , Microsoft.NET.Runtime.WebAssembly.Sdk , Microsoft.NETCore.App.Ref , Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.browser-wasm , Microsoft.NETCore.App.Runtime.win-x64 , Microsoft.NETCore.BrowserDebugHost.Transport , Microsoft.NETCore.Platforms , System.Collections.Immutable , System.Composition , System.Configuration.ConfigurationManager , System.Diagnostics.DiagnosticSource , System.Diagnostics.EventLog , System.Diagnostics.PerformanceCounter , System.DirectoryServices.Protocols , System.IO.Hashing , System.IO.Pipelines , System.Net.Http.Json , System.Net.Http.WinHttpHandler , System.Reflection.Metadata , System.Resources.Extensions , System.Runtime.Caching , System.Security.Cryptography.Pkcs , System.Security.Cryptography.Xml , System.Security.Permissions , System.ServiceProcess.ServiceController , System.Text.Encodings.Web , System.Text.Json , System.Threading.AccessControl , System.Threading.Channels , System.Threading.RateLimiting , Microsoft.SourceBuild.Intermediate.runtime.linux-x64
 From Version 9.0.0-preview.4.24222.10 -> To Version 9.0.0-preview.4.24227.4

* fix reflection

* readonly

* Update dependencies from https://github.com/dotnet/runtime build 20240430.10

Microsoft.Bcl.AsyncInterfaces , Microsoft.Bcl.TimeProvider , Microsoft.Extensions.Caching.Abstractions , Microsoft.Extensions.Caching.Memory , Microsoft.Extensions.Configuration , Microsoft.Extensions.Configuration.Abstractions , Microsoft.Extensions.Configuration.Binder , Microsoft.Extensions.Configuration.CommandLine , Microsoft.Extensions.Configuration.EnvironmentVariables , Microsoft.Extensions.Configuration.FileExtensions , Microsoft.Extensions.Configuration.Ini , Microsoft.Extensions.Configuration.Json , Microsoft.Extensions.Configuration.UserSecrets , Microsoft.Extensions.Configuration.Xml , Microsoft.Extensions.DependencyInjection , Microsoft.Extensions.DependencyInjection.Abstractions , Microsoft.Extensions.DependencyModel , Microsoft.Extensions.Diagnostics , Microsoft.Extensions.Diagnostics.Abstractions , Microsoft.Extensions.FileProviders.Abstractions , Microsoft.Extensions.FileProviders.Composite , Microsoft.Extensions.FileProviders.Physical , Microsoft.Extensions.FileSystemGlobbing , Microsoft.Extensions.HostFactoryResolver.Sources , Microsoft.Extensions.Hosting , Microsoft.Extensions.Hosting.Abstractions , Microsoft.Extensions.Http , Microsoft.Extensions.Logging , Microsoft.Extensions.Logging.Abstractions , Microsoft.Extensions.Logging.Configuration , Microsoft.Extensions.Logging.Console , Microsoft.Extensions.Logging.Debug , Microsoft.Extensions.Logging.EventLog , Microsoft.Extensions.Logging.EventSource , Microsoft.Extensions.Logging.TraceSource , Microsoft.Extensions.Options , Microsoft.Extensions.Options.ConfigurationExtensions , Microsoft.Extensions.Options.DataAnnotations , Microsoft.Extensions.Primitives , Microsoft.Internal.Runtime.AspNetCore.Transport , Microsoft.NET.Runtime.MonoAOTCompiler.Task , Microsoft.NET.Runtime.WebAssembly.Sdk , Microsoft.NETCore.App.Ref , Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.browser-wasm , Microsoft.NETCore.App.Runtime.win-x64 , Microsoft.NETCore.BrowserDebugHost.Transport , Microsoft.NETCore.Platforms , System.Collections.Immutable , System.Composition , System.Configuration.ConfigurationManager , System.Diagnostics.DiagnosticSource , System.Diagnostics.EventLog , System.Diagnostics.PerformanceCounter , System.DirectoryServices.Protocols , System.IO.Hashing , System.IO.Pipelines , System.Net.Http.Json , System.Net.Http.WinHttpHandler , System.Reflection.Metadata , System.Resources.Extensions , System.Runtime.Caching , System.Security.Cryptography.Pkcs , System.Security.Cryptography.Xml , System.Security.Permissions , System.ServiceProcess.ServiceController , System.Text.Encodings.Web , System.Text.Json , System.Threading.AccessControl , System.Threading.Channels , System.Threading.RateLimiting , Microsoft.SourceBuild.Intermediate.runtime.linux-x64
 From Version 9.0.0-preview.4.24222.10 -> To Version 9.0.0-preview.4.24230.10

---------

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Javier Calvarro Nelson <[email protected]>
Co-authored-by: Brennan <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants