-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Environment sdk version restriction negatively affects dotnet tools #153
Comments
I think enabling |
One thing I discovered with Ionide is that when an app targets net5.0 and is rolled forward to a newer runtime, the System.Environment.Version values don't seem to update to those of the runtime. This killed my ability to use this library entirely, since a thte time we targeted net5.0 for reach and enabled roll-forward as you describe. |
If true, please file a bug in dotnet/runtime. That sounds very incorrect. |
I'm not seeing this. <Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<RollForward>LatestMajor</RollForward>
</PropertyGroup>
</Project> using System; namespace Net5Rollforward
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(System.Environment.Version);
}
}
} S:\play\Net5Rollforward via .NET v7.0.100-preview.5.22307.18 🎯 net5.0
❯ dotnet run
7.0.0 |
Well that's very interesting. I can't find my notes from the tire fire that was this pr, but a finding like that is what led me to rip it all out. Perhaps its time for a more measured look again. |
It has been recently addressed in scope of this ticket. |
@YuliiaKovalova can you please link the PR or commit to see how that was fixed? I don't see any PR in the issue you mentioned |
Hi @Lanayx and @JoeRobich , You can test the changes in the scope of the recently released package: Please let us know if you have any questions/concerns. |
Here are the links to the main sympthoms
MessagePack-CSharp/MessagePack-CSharp#1387
fsprojects/FSharpLint#536
The root of the issue seems to be these lines:
So if library is built with .net5.0 and then used on the environment with just .net6.0 is installed it fails, because the check above returns null. At the same time there shouldn't be any restrictions of running tools on higher versions of sdk's.
The text was updated successfully, but these errors were encountered: