.net - Visual Studio 检测旧的 Azure Functions 核心工具版本

标签 .net azure visual-studio azure-functions

我有一个 Azure Function 项目,我想使用 Azure Functions Core Tools v4.x 运行该项目。但 Visual Studio 始终选择 Azure Functions Core Tools 2.6。这样,我收到以下错误:

You are using an outdated version of the Azure Functions Core Tools. For more information, please see: https://aka.ms/func-v2-upgrade

我删除了 %LocalData%/AzureFunctionTools/Releases/ 中的所有 Azure Functions Core Tools 运行时。但当我再次运行该项目时,Azure Function Tools 2.6 版本正在安装。

如何更改它以使用 4.x 版本?

我正在使用:

  • Visual Studio 2022
  • Windows 11
  • .NET Core 2.2

更新:

I found this article on the internet 。但仅仅向项目添加新功能对我来说不起作用。但是当我创建新项目时,它选择最新版本的 Azure Function Core Tools 4.x 。我仍然不知道如何对现有项目执行此操作。

最佳答案

就我而言,尽管安装了较新的版本,但 Visual Studio 2022 仍在使用旧版本的函数运行时。

这来自以下文件夹: C:\Users<用户名>\AppData\Local\AzureFunctionsTools

即使删除了文件夹内容,它们每次都会重新生成,但仅限于旧版本。

我必须转到 Visual Studio 设置,在那里我找到了一种更新到最新版本的函数工具的方法。其他地方没有任何通知要求我升级。

enter image description here

关于.net - Visual Studio 检测旧的 Azure Functions 核心工具版本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/75659559/

相关文章:

c# - 从 C# 解决方案调试 C++ 解决方案

visual-studio - MSVC fatal error LNK1120 : 1 unresolved externals with FFMPEG libs

c# - 从 .NET 2.0 应用程序调用 .NET 4.0 WPF 类库

c# - 将我的项目中的表单添加到另一个项目

c# - 获取文件夹的根目录 +1

azure - Windows Azure 帐户的多个管理员

Azure 搜索索引器无法检索从 DocumentDB 中的文档归档的 GeographyPoint

.net - 使用 babel 混淆器混淆多个相关的 .NET 程序集

具有应用服务的 Azure 应用程序网关

visual-studio - LNK2005 将静态 openCV 库与 Visual Studio 和 QT Creator 链接时出错