调试netcore3.0网站遇到以下错误:

An unhandled exception occurred while processing the request.
InvalidOperationException: Cannot find compilation library location for package 'System.Security.Permissions'
Microsoft.Extensions.DependencyModel.CompilationLibrary.ResolveReferencePaths(ICompilationAssemblyResolver resolver, List<string> assemblies)

其实原因就是 各依赖包冲突所致,我的是myslq 8 驱动引起的。解决办法很简单 把netcore3.0 升级成 netcore3.1 再把相关的依赖包升级成稳定版本就可以了。3.0毕竟是个过渡版本。