You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Build F# repo with .Net 6.0 because, F# Interactive built in main is still net5.0 #12733
When running F# Interactive it can't load a .NET 6 DLL. because fsi.exe is still .NET 5.0
@brettfo This was the error I mentioned to you on teams. Here the script is doing #r on a .NET 6 DLL.
This isn't a repro but an example of the kind of problem we get:
>\GitHub\dsyme\fsharp\artifacts\bin\fsi\Debug\net5.0\fsi.exe --legacyemit train.fsx --model cnn
System.TypeLoadException: Could not load type 'System.IO.DirectoryInfo' from assembly 'System.Runtime, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
at Helpers.Utils.createDir(String dir)
at <StartupCode$FSI_0003>.$FSI_0003.main@()
Stopped due to error
It looks like this is only the case for the fsi.exe we build in main. I've checked the release branches and they seem to also build net5.0, however when you run dotnet fsi from the .NET SDK it chooses an fsi.dll which runs .NET 6.0 bits
The shipped SDK always contain fsi and fsc that are built to match the sdk shipped the build of the runtime contained in that specific SDK. So the released bits will always be correct, however, the repo is always going to lag a bit, especially since previews of dotnet 7. are pretty soon going to be released.
I will chat with Brett and see if there is something interesting we can do that makes this less of a problem
changed the title [-]F# Interactive built in main is still net5.0 [/-][+]Build F# repo with .Net 6.0 because, F# Interactive built in main is still net5.0 [/+]on Mar 3, 2022
Activity
dsyme commentedon Feb 16, 2022
It looks like this is only the case for the
fsi.exewe build inmain. I've checked the release branches and they seem to also buildnet5.0, however when you rundotnet fsifrom the .NET SDK it chooses an fsi.dll which runs .NET 6.0 bits[-]F# Interactive is still net5.0 [/-][+]F# Interactive built in main is still net5.0 [/+]KevinRansom commentedon Feb 16, 2022
The shipped SDK always contain fsi and fsc that are built to match the sdk shipped the build of the runtime contained in that specific SDK. So the released bits will always be correct, however, the repo is always going to lag a bit, especially since previews of dotnet 7. are pretty soon going to be released.
I will chat with Brett and see if there is something interesting we can do that makes this less of a problem
KevinRansom commentedon Mar 1, 2022
now builds net6.0: #12769
[-]F# Interactive built in main is still net5.0 [/-][+]Build F# repo with .Net 6.0 because, F# Interactive built in main is still net5.0 [/+]