fslaborg / flips

Fsharp LInear Programming System
https://flipslibrary.com/#/
MIT License
251 stars 32 forks source link

why is #r "nuget: Flips,2.4.4" saying .net framework and not netstandard? #171

Closed nhirschey closed 3 years ago

nhirschey commented 3 years ago

See below. I checked the google.ortools website, and it seems to say that it is netstandard. Why isn't flips pulling it in as netstandard?

I am on windows, .net 5.0.200.

- #r "nuget: Flips, 2.4.4"
- ;;
C:\Users\nicho\AppData\Local\Temp\nuget\5000--4c0436a8-8001-4579-9353-44451b77434d\Project.fsproj : warning NU1701: Package 'Google.OrTools.runtime.win-x64 8.1.8487' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net5.0'. This package may not be fully compatible with your project.
C:\Users\nicho\AppData\Local\Temp\nuget\5000--4c0436a8-8001-4579-9353-44451b77434d\Project.fsproj : warning NU1701: Package 'Google.OrTools.runtime.win-x64 8.1.8487' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework 'net5.0'. This package may not be fully compatible with your project.
[Loading C:\Users\nicho\AppData\Local\Temp\nuget\5000--4c0436a8-8001-4579-9353-44451b77434d\Project.fsproj.fsx]
namespace FSI_0002.Project
matthewcrews commented 3 years ago

That is a great question that I have not been able to figure out. I have tried repeatedly to get the package manager to pull in the netstandard version with no luck. I have found that the library still works though. I believe it has something to do with how Google OR Tools publishes since this didn't used to be an issue two versions ago for the OR Tools library.

nhirschey commented 3 years ago

Thanks for that info. I just wasn’t sure if it was my install or a general thing.

Would paket framework restrictions help? I don’t know how this interacts with the *.fproj target framework, but it might force getting the netstandard version of Google OR. Just a thought, not sure if it’s a fix.

https://fsprojects.github.io/Paket/dependencies-file.html#Framework-restrictions

smoothdeveloper commented 3 years ago

@nhirschey / @matthewcrews worth bringing the issue to OR tools repository if it used to work in previous release with both netstandard and framework, they'll be able to track what changed in the delivery pipeline.

Their engineering team gave me very quick turnaround in a previous interaction.

@nhirschey are you able to proceed by discarding the warnings?

matthewcrews commented 3 years ago

@nhirschey I did try restrictions with Paket and it did not help. I'll try reaching out the the Google OR Tools team about this.

nhirschey commented 3 years ago

Just for confirmation, the intro problem works on my machine despite the warning.

realvictorprm commented 8 months ago

It would still be great to be able to get rid of that warning in F# interactive, while using it with .NET 8 (I expect it to appear with the other .NET versions too).

warning NU1701: Package 'Google.OrTools.runtime.win-x64 9.0.9048' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8, .NETFramework,Version=v4.8.1' instead of the project target framework 'net8.0'. This package may not be fully compatible with your project.

realvictorprm commented 8 months ago

Not sure how your view is on this issue but maybe it would be these days sufficient to just update the Google.Or lib to the newest version @matthewcrews

matthewcrews commented 8 months ago

Yeah, I'll get that taken care of today