Impact of the DNX SDK version in ASP.NET5 development

Source: Internet
Author: User

A very strange problem encountered in the development of a ASP.NET5, the NuGet package of the reference part did not show any errors, such as:

But there were hundreds of errors at compile time:

Errors are basically shaped like "CS0246 the type or namespace name ' Key ' could not being found (is you missing a using directive or an assembly Refe Rence?) "This error,

The first thing that comes to mind is that the NuGet package refers to a problem, but no matter how you check it, you can't find out what's wrong.

Even more bizarre, this solution in the company can be compiled normally, at night home debugging only to appear this situation. Later carefully considered a bit, because at that time, the beta7 just updated, the middle of a long time, it is suspected that the DNX version of the problem.

Then I checked the project properties, found that the solution worked under BETA5, and the NuGet package was updated to Beta7,

That is, the version of the reference package and the work version of the solution is inconsistent, to solve the problem is very simple, the work version is also changed to BETA7 version can be:

And then recompile, everything works.

ASP.NET5 development, there are a lot of similar problems, especially when setting the version of the dependencies package in Project.json, be sure to keep the version consistent.

Impact of the DNX SDK version in ASP.NET5 development

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.