无法在 Visual Studio Mac 中更新 Azure Functions Core Tools
Unable to update Azure Functions Core Tools in Visual Studio Mac
我正在开发一个 Azure Functions 应用程序,它具有各种不同的触发器(HTTP、QUEUE、TIMER 和 SignalR)。当我在我的工作 PC (Windows) 上开发时它们工作正常,但当我在我的 Mac.
上在家开发时它们不工作
我收到以下错误:
A host error has occurred
[28/03/2019 20:37:53] Microsoft.Azure.WebJobs.Extensions.Storage: Could not load type 'Microsoft.Azure.WebJobs.Hosting.IOptionsFormatter' from assembly 'Microsoft.Azure.WebJobs.Host, Version=3.0.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'.
Value cannot be null.
Parameter name: provider
只有当我添加(到一个干净的项目)Microsoft.Azure.WebJobs.Extensions.Storage nuget 包时才会出现此错误。
事实证明,我 运行 与 is, following up on BrettSam's advice I try to update the CLI via Brew as per the docs and also via NPM as per
完全相同的 SDK 版本
然而,正如您在这里看到的,没有任何效果
有什么想法吗?
Visual Studio for Mac 7 不支持使用 Homebrew 安装 Azure Functions Core Tools。 Visual Studio for Mac 7 附带了一份工具副本,并且只会使用这些工具。
Visual Studio for Mac 8 确实支持这一点。它还具有一个内置功能,可以在发现模板和 Azure Functions Core Tools 本身已过时时在本地目录中对其进行更新。 Azure Functions 团队提供了一个在线订阅源,Visual Studio for Mac 将使用该订阅源。此更新功能可用于在新项目中创建新的 Azure Functions 项目。
如果 Visual Studio 用于 Mac 7,您可以将更新版本的工具复制到目录:
/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/AddIns/MonoDevelop.AzureFunctions/azure-functions-cli/
不过,我会先备份该目录或整个 Visual Studio.app
,然后再尝试更新这些文件,这样如果它不起作用,您可以回滚。
我正在开发一个 Azure Functions 应用程序,它具有各种不同的触发器(HTTP、QUEUE、TIMER 和 SignalR)。当我在我的工作 PC (Windows) 上开发时它们工作正常,但当我在我的 Mac.
上在家开发时它们不工作我收到以下错误:
A host error has occurred [28/03/2019 20:37:53] Microsoft.Azure.WebJobs.Extensions.Storage: Could not load type 'Microsoft.Azure.WebJobs.Hosting.IOptionsFormatter' from assembly 'Microsoft.Azure.WebJobs.Host, Version=3.0.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. Value cannot be null. Parameter name: provider
只有当我添加(到一个干净的项目)Microsoft.Azure.WebJobs.Extensions.Storage nuget 包时才会出现此错误。
事实证明,我 运行 与
然而,正如您在这里看到的,没有任何效果
有什么想法吗?
Visual Studio for Mac 7 不支持使用 Homebrew 安装 Azure Functions Core Tools。 Visual Studio for Mac 7 附带了一份工具副本,并且只会使用这些工具。
Visual Studio for Mac 8 确实支持这一点。它还具有一个内置功能,可以在发现模板和 Azure Functions Core Tools 本身已过时时在本地目录中对其进行更新。 Azure Functions 团队提供了一个在线订阅源,Visual Studio for Mac 将使用该订阅源。此更新功能可用于在新项目中创建新的 Azure Functions 项目。
如果 Visual Studio 用于 Mac 7,您可以将更新版本的工具复制到目录:
/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/AddIns/MonoDevelop.AzureFunctions/azure-functions-cli/
不过,我会先备份该目录或整个 Visual Studio.app
,然后再尝试更新这些文件,这样如果它不起作用,您可以回滚。