Problem with Azure Functions Core Tools

zuzanna.czaja@ichoosr.com 25 Reputation points
2024-10-08T12:38:20.8+00:00

My old project still starts in Azure Functions Core Tools Core Tools Version 4.0.1 and my new project starts in version 4.0.6280. I updated everything in the old project and it still starts in the old version, how to change it?

I think that's also why the project doesn't want to start when I try to start it via Visual Studio. I keep getting this error:

User's image

I updated everything:

  1. I updated project .NET 6 to .NET 8
  2. I added "FUNCTIONS_INPROC_NET8_ENABLED": "1" to local.settings.json,
  3. I updated Microsoft.NET.Sdk.Functions to 4.4.1
Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,911 questions
0 comments No comments
{count} votes

Accepted answer
  1. LeelaRajeshSayana-MSFT 17,766 Reputation points Moderator
    2024-10-10T14:54:20.45+00:00

    Hi @******@ichoosr.com I'm glad that you were able to resolve your issue and thank you for posting your solution so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", I'll repost your solution in case you'd like to accept the answer.

    Error Message:

    There is no Functions version available that matches with the version specified in the project.

    Issue:

    Tried to update the Azure Core tools version in old project to newer version and encountered this issue.

    Solution:

    With the .csproj file the version has to passed through AzureFunctionsVersion attribute and it has to be v4 which is case sensitive. Using the value as V4 caused this issue. Below are the correct settings

    <PropertyGroup>
            <TargetFramework>net8.0</TargetFramework>
            <AzureFunctionsVersion>v4</AzureFunctionsVersion>
        </PropertyGroup>
    
    

    If I missed anything please let me know and I'd be happy to add it to my answer, or feel free to comment below with any additional information.

    I hope this helps!

    If you have any other questions, please let me know. Thank you again for your time and patience throughout this issue.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. zuzanna.czaja@ichoosr.com 25 Reputation points
    2024-10-09T07:05:43.14+00:00

    I resolved my problem. The letter 'v' must be in lower case, and in my project it was in upper case in AzureFunctionsVersion.

        <PropertyGroup>
            <TargetFramework>net8.0</TargetFramework>
            <AzureFunctionsVersion>v4</AzureFunctionsVersion>
        </PropertyGroup>
    
    1 person found this answer helpful.

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.