skip to Main Content

All of our Azure function apps are failing to execute manually from the Azure Portal. When we go to do Test/Run for any of our functions in any function app, we get the following error:

Http response code: 0 Unknown HTTP error

Http response content: Error: {"message":"Failed to fetch","stack":"TypeError: Failed to fetchn at https://portal.azure.com/Content/Dynamic/fOu-tO_OJd0O.js:226:23724","isError":true}

enter image description here

All of our functions are configured the following way:

  • FUNCTIONS_EXTENSION_VERSION = ~4
  • FUNCTIONS_WORKER_RUNTIME = dotnet-isolated
  • CORS -> Allowed Origins = https://portal.azure.com
  • All C# code is .net 8

Executing manually from the Azure portal was working a week or two ago, and we’ve not made any changes that we can think of. Any ideas?

2

Answers


  1. I got the same error when I deployed .NET 8.0 isolated Azure functions from visual studio to Azure function app.

    enter image description here

    To resolve this, click on CORS URL in the warning=> it redirects to the CORS page. In the "Allowed Origins" section, add * to allow access to all origins.

    • Check if the allowed origin is reflecting under CORS after updating successfully.

    enter image description here

    Application Settings of function app:

    enter image description here

    Able to run the function as expected after enabling CORS.

    enter image description here

    Login or Signup to reply.
  2. We are experiencing the same issue. Azure Functions were running perfectly until two weeks ago. However, for the past two weeks, we have been unable to test them due to receiving a "0 Unknown HTTP error" on the "Code + Test" tab of the Azure Function.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search