简体   繁体   中英

Issue: Referring .Net Standard 2.1 project in .Net Core 3.1

My main project is in .net standard 2.1 my test project is in .net core 3.1

when ever i'm trying to build the solution I'm getting the below error

NU1201: Project xxx is not compatible with netcoreapp3.1 (.NETCoreApp,Version=v3.1). Project yyy supports: netstandard2.1 (.NETStandard,Version=v2.1)

Can some one help me in resolving this issue

We got this error too. The reason for this is that we use our own nuget server (which was proget 4.x). Each time we need a nuget we download it from nuget.org and add it to our own nuget server. The Microsoft.IdentityModel.Protocols.OpenIdConnect 5.5.0 nuget is a signed nuget however. Out nuget server didn't support this and it complained when we added the nuget. However, the nuget did get added - only it was not signed anymore and did not contain the dll's (which is really weird). I know this sounds bizar but this is exactly what happened. We temporarily solved this by adding the official nuget feed next to our own private feed while building (as first choice). That solved our problem. I'm just posting this in th eunlikely event you have the same issue.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM