Skip to content

[Regression] Azure Functions resource fails because the generated func task type is unregistered #19284

Description

@adamint

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

During 1.17.0 release verification, an Azure Functions resource consistently failed after the Aspire extension called the real Azure Functions extension API.

The AppHost starts, the Functions project builds, and the Aspire extension gets Azure Functions API 1.10.0 from ms-azuretools.vscode-azurefunctions 1.22.0. startFuncProcess then creates a task named func: host start with this definition type:

func  <workspace>/AspireE2E.Functions/bin/Debug/net8.0

VS Code rejects it as an unregistered task type. The task ends immediately, the Functions host never starts, and the Aspire extension eventually reports that it could not detect the host.

The exact task-provider error was previously reported in a comment on #16997. That issue was closed after the path was expected to be fixed with 13.4, so this looks like a 13.5 regression. #18674/#18676 cover the separate func host start versus func run mismatch.

Expected Behavior

The Azure Functions resource should start through the installed Azure Functions extension, and the generated task type should have a registered provider.

Steps To Reproduce

  1. Install the Aspire VS Code extension, C# extension, and Azure Functions extension.

  2. Create an AppHost containing:

    var builder = DistributedApplication.CreateBuilder(args);
    builder.AddAzureFunctionsProject("functions", "../Functions/Functions.csproj");
    builder.Build().Run();
  3. Run the AppHost without debugging from VS Code.

  4. Open the Tasks output.

Exceptions (if any)

Error: there is no registered task type
'func  <workspace>/AspireE2E.Functions/bin/Debug/net8.0'.
Did you miss installing an extension that provides a corresponding task provider?

The Aspire extension then reports:

Azure Functions extension failed to start func host:
Failed to detect running Functions host within "30" seconds.

Aspire doctor output

Release-shaped inputs:

  • Aspire VS Code extension 1.17.0, commit c66c0f80e4748e07d079e68c74dd3abf3d27a604
  • Aspire CLI/AppHost 13.5.0, commit 1d922813c0f9bc14f7d817c817a8ab46b288bb44
  • C# 2.148.23, darwin-arm64
  • Azure Functions 1.22.0
  • VS Code 1.130.0 control on macOS arm64

Anything else?

The run used a fresh hermetic NuGet cache and a locally built release hive with 103 unique Aspire package IDs, all exactly version 13.5.0. The platform-correct C# extension activated successfully, and a direct CLI control with the same package hive launched the AppHost.

ExTester cannot use the Microsoft .NET debugger in its downloaded VS Code build, so the automated control suppressed only AppHost IDE delegation. The real azure-functions capability, Azure Functions API, startFuncProcess call, generated task, CLI, hosting packages, and Functions project were unchanged.

Azure Functions task provider regression proof

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-integrationsIssues pertaining to Aspire Integrations packagesarea-vscodetriage:bot-seenAspire triage bot has seen this issue

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions