4 ms·
This exactly! The branding and versioning of .NET is a complete disaster. There's .NET Framework (where even simply getting the current runtime version requires
by 0x0 5y ago
This exactly! The branding and versioning of .NET is a complete disaster. There's .NET Framework (where even simply getting the current runtime version requires several convoluted hoops, since System.Environment.Version has gone the way of browser user agents and frozen itself at "4.0.30319").
Then there is .NET Standard, which was at version 1 and 2 (which are newer than .NET Framework 4.0 or 4.5? but have significantly fewer APIs available, and many classes are missing methods and properties that were present in .NET Framework).
Then there is .NET Core which reset the versioning scheme again?
Then there is .NET 5 which is newer than all of these, but is it actually fully supported on non-windows platforms?
Then you need Newtonsoft.JSON, and then you get to watch your entire project blow up because you have three different dependencies that use different versions of netstandard/netcore/netframework and the assemblies aren't compatible.
I really hope going forward there will be just one unified .NET 6 that works the same on all platforms and doesn't need a million different builds of the same nuget package.
Edit: And even after all this, deploying your app by just copying the .exe and .dlls to a pristine machine often fails, because the corresponding .NET framework runtime isn't installed. And then you need to be a lawyer to figure out if you can even ship the net framework installer to your customer or how to handle that. You would think Microsoft would have a better story to sell to developers as what should be "the way" to develop and distribute windows executables. It seems like the only way to really be portable is to use an ancient version of Visual C to write win32 directly, and link the corresponding msvcrt statically.
- nightski 5y agoYes .NET 5 is supported on all platforms. It is the future of .NET Core. They dropped core because they wanted to make it clear it is the one true dotnet going forward. It actually will greatly simplify things going forward. .NET standard will no longer be necessary because there is only .NET 5 onward. You don't "need" Newtonsoft.JSON. .NET now has a built in serializer which is much faster. But for compatability and some more advanced scenarios some people still need/prefer it. Lastly .NET core apps (and .NET 5/6 going forward) have an option to produce a single file deployment. This includes the framework so you do not have to have it pre-installed on the target.
- sebazzz 5y ago> Then there is .NET Standard, which was at version 1 and 2 (which are newer than .NET Framework 4.0 or 4.5? but have significantly fewer APIs available, and many classes are missing methods and properties that were present in .NET Framework). You seem to think that .NET Standard is a framework. It is a specification, like the C++ STL. Think of it as "the .NET Standard".
- 0x0 5y agoThe newtonsoft json dlls (and other) distribution contains different dlls in different folders called "net45", "netstandard2.0", "portable-net40+sl5" etc. So it is obviously more than just a specification, since binary dlls can target different values of "netstandard" in addition to .net framework and .net core.
- sebazzz 5y agoHigher netstandard versions have more APIs. For performance or compatibility reasons, you can also target specific frameworks.