Dot-Net-Core
.NET Core 2.1 ConfigurationBuilder.Build() - StackOverflowException
我已經安裝了 VS 2017 Preview 和2.1.300-preview2-008530 SDK。現在,在我的 Web 應用程序項目中,以下序列會生成 StackOverflowException:
var builder = new ConfigurationBuilder() .SetBasePath(env.ContentRootPath) .AddJsonFile("appsettings.json");NET Core 2.1 Preview 2 Known Issues - 不包含與我的問題相關的任何內容。
添加此包 Microsoft.Extensions.Configuration.json
升級到 2.1 後我遇到了同樣的問題,並在 microsoft online doc 上找到了這個答案