"方法未找到:'System.Text.Json.JsonEncodedText System.Text.Json.JsonEncodedText.Encode(System.String,Syst



当我尝试使用Azure时。搜索在Azure函数中的文档中,抛出了Json异常。

环境摘要:VS代码,HttpTrigger Azure函数:V3,netcoreapp3.1

相同的完整堆栈跟踪是:

"在Azure。搜索文件。模型。SearchResults1.DeserializeAsync(Stream json, ObjectSerializer serializer, Boolean async, CancellationToken cancellationToken)rn at Azure.Search.Documents.SearchClient.SearchInternal[T](SearchOptions options, String operationName, Boolean async, CancellationToken cancellationToken)rn at Azure.Search.Documents.SearchClient.SearchInternal[T](String searchText, SearchOptions options, Boolean async, CancellationToken cancellationToken)rn at Azure.Core.Pipeline.TaskExtensions.EnsureCompleted[T](Task1任务(。搜索文件。SearchClient。在SearchService上搜索[T](字符串searchText、SearchOptions选项、CancellationToken取消令牌(\r\n。公用事业RunQueries(SearchClient srchclient,String inputVal,String gender,String body_part,String age_group(">

这是由azure函数中的库不匹配引起的。正在安装最新版本的系统。文本Json确保函数具有正确的可用方法。

相关内容

最新更新