Skip to content

Refactor Hosting extensions #2450

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

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Add new HostingAction that uses .NET Generic Host Hosted Service

7f36552
Select commit
Loading
Failed to load commit list.
Draft

Refactor Hosting extensions #2450

Add new HostingAction that uses .NET Generic Host Hosted Service
7f36552
Select commit
Loading
Failed to load commit list.
Azure Pipelines / command-line-api (Build and Test Ubuntu Debug) failed Mar 31, 2025 in 1m 24s

Build and Test Ubuntu Debug failed

Annotations

Check failure on line 11 in src/System.CommandLine.Hosting/HostApplicationBuilderAction.cs

See this annotation in the file changed.

@azure-pipelines azure-pipelines / command-line-api (Build and Test Ubuntu Debug)

src/System.CommandLine.Hosting/HostApplicationBuilderAction.cs#L11

src/System.CommandLine.Hosting/HostApplicationBuilderAction.cs(11,66): error CS0649: (NETCORE_ENGINEERING_TELEMETRY=Build) Field 'HostApplicationBuilderAction._createHostBuilder' is never assigned to, and will always have its default value null

Check failure on line 32 in src/System.CommandLine.Hosting.Tests/HostingTests.cs

See this annotation in the file changed.

@azure-pipelines azure-pipelines / command-line-api (Build and Test Ubuntu Debug)

src/System.CommandLine.Hosting.Tests/HostingTests.cs#L32

src/System.CommandLine.Hosting.Tests/HostingTests.cs(32,18): error CS1061: (NETCORE_ENGINEERING_TELEMETRY=Build) 'CommandLineConfiguration' does not contain a definition for 'UseHost' and no accessible extension method 'UseHost' accepting a first argument of type 'CommandLineConfiguration' could be found (are you missing a using directive or an assembly reference?)

Check failure on line 45 in src/System.CommandLine.Hosting.Tests/HostingTests.cs

See this annotation in the file changed.

@azure-pipelines azure-pipelines / command-line-api (Build and Test Ubuntu Debug)

src/System.CommandLine.Hosting.Tests/HostingTests.cs#L45

src/System.CommandLine.Hosting.Tests/HostingTests.cs(45,18): error CS1061: (NETCORE_ENGINEERING_TELEMETRY=Build) 'CommandLineConfiguration' does not contain a definition for 'UseHost' and no accessible extension method 'UseHost' accepting a first argument of type 'CommandLineConfiguration' could be found (are you missing a using directive or an assembly reference?)

Check failure on line 19 in src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs

See this annotation in the file changed.

@azure-pipelines azure-pipelines / command-line-api (Build and Test Ubuntu Debug)

src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs#L19

src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs(19,37): error CS1061: (NETCORE_ENGINEERING_TELEMETRY=Build) 'HostingHandlerTest.MyRootCommand' does not contain a definition for 'UseCommandHandler' and no accessible extension method 'UseCommandHandler' accepting a first argument of type 'HostingHandlerTest.MyRootCommand' could be found (are you missing a using directive or an assembly reference?)

Check failure on line 36 in src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs

See this annotation in the file changed.

@azure-pipelines azure-pipelines / command-line-api (Build and Test Ubuntu Debug)

src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs#L36

src/System.CommandLine.Hosting.Tests/HostingHandlerTest.cs(36,75): error CS1061: (NETCORE_ENGINEERING_TELEMETRY=Build) 'HostingHandlerTest.MyRootCommand' does not contain a definition for 'UseCommandHandler' and no accessible extension method 'UseCommandHandler' accepting a first argument of type 'HostingHandlerTest.MyRootCommand' could be found (are you missing a using directive or an assembly reference?)