Update Oryx feature to install if a newer version of .NET is present - #769
Update Oryx feature to install if a newer version of .NET is present#769seesharprun wants to merge 6 commits into
Conversation
|
This PR is an attempt to resolve: |
|
There is still some more work that needs to be done. Even on my local machine, I can't build Oryx from source if I have both .NET 7 and .NET 8 installed. |
|
It looks like the feature runs Instead it should check |
|
A little more investigating has uncovered that some of the assemblies (Ex: Microsoft.NET.Sdk.Razor/source-generators/Microsoft.NET.Sdk.Razor.SourceGenerators.dll) will always use the latest .NET version if multiple versions are enabled. I looked around on GitHub and found a couple of example issues where the .NET team says this is intentional behavior. They don't want someone to "freeze" on an old dependency and lock it in for years after moving on to newer versions of .NET. |
|
I have a new PR open on the Oryx repo to see if they are willing to bump their .NET 7-locked dependencies forward so the project can be built on both a .NET 7 and a .NET 7 + 8 environment. |
|
Feel free to close this in favor of #825 which should unblock devcontainers/images#855 |
Oryx fails to install if a newer version of .NET is present.
I suspect this is due to a missing
--frameworkargument.I also took this opportunity to spell out the full name of other
dotnet buildanddotnet publisharguments to make it easier to debug for the person that comes next.