logicapps icon indicating copy to clipboard operation
logicapps copied to clipboard

Failed to initialize worker provider

Open sschutten opened this issue 5 months ago • 5 comments

Severity

P2 - High (Major functionality broken)

Describe the Bug with repro steps

When I try to debug a logic app with custom code in VS Code I get the error message: "Failed to find the .NET host child process for the functions project for logic app". In the output window I see the following failures:

Failed to initialize worker provider for: C:\Users\SanderSchutten\.azure-functions-core-tools\Functions\ExtensionBundles\Microsoft.Azure.Functions.ExtensionBundle.Workflows\1.131.9\CustomCodeNetFxWorker\net8
System.Text.Json: '0xFF' is an invalid start of a value. LineNumber: 0 | BytePositionInLine: 0.
Failed to initialize worker provider for: C:\Users\SanderSchutten\.azure-functions-core-tools\Functions\ExtensionBundles\Microsoft.Azure.Functions.ExtensionBundle.Workflows\1.131.9\CustomCodeNetFxWorker\net472
System.Text.Json: '0xFF' is an invalid start of a value. LineNumber: 0 | BytePositionInLine: 0.

Steps to reproduce:

  • Follow these steps to create a new project: https://learn.microsoft.com/en-us/azure/logic-apps/create-run-custom-code-functions#create-a-code-project
  • Debug the project

What type of Logic App Is this happening in?

Standard (VSCode)

Are you experiencing a regression?

Also doesn't work with Microsoft.Azure.Functions.ExtensionBundle.Workflows version 1.123.44 or 1.127.24

Which operating system are you using?

Windows

Did you refer to the TSG before filing this issue? https://aka.ms/lauxtsg

Yes

Workflow JSON


Screenshots or Videos

No response

Environment

  • VS Code: 1.102.3
  • VS Code Extension: 5.130.7
  • Microsoft.Azure.Functions.ExtensionBundle.Workflows: 1.131.9

Additional context

I made sure the FUNCTIONS_WORKER_RUNTIME is set to 'dotnet' and FUNCTIONS_INPROC_NET8_ENABLED is set to '1' in the local.settings.json:

"FUNCTIONS_INPROC_NET8_ENABLED": "1",
"FUNCTIONS_WORKER_RUNTIME": "dotnet",

I've tried older versions of the Microsoft.Azure.Functions.ExtensionBundle.Workflows extension bundle, as suggested in Azure/LogicAppsUX#7742, but they give the same error

I tried removing all extension bundles, reinstalling the VS Code extension, reboot my machine.

sschutten avatar Jul 31 '25 14:07 sschutten