-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Create "empty" Microsoft.NETCore.App package to support a 3.0 workaround #3528
Comments
You might need to do runtime packs first so that the current old targeting packs don't become .Internal and break things |
I don't think that will be a problem based on how the infra is set up, but I'll keep the order flexible if something pops up. |
I normally run with There are generic "the world is ending" compilation errors like:
but more specifically the runtime packages are missing:
I'm not really familiar with the tests but I think this is to be expected because Core-Setup is on SDK The first thing that comes to mind is creating:
I haven't looked deeper into the problem yet though, like if it would be reasonable to add @dsplaisted @nguerrera @ericstj @johnbeisner any thoughts? |
This is actually easy to do non-intrusively... I can add this in the mix to use the insertion package when necessary: <ItemGroup Condition="'$(TargetFramework)' == 'netcoreapp$(NETCoreAppMaximumVersion)'">
<PackageReference Include="Microsoft.NETCore.App.Insertion" Version="$(MNAVersion)" />
</ItemGroup> One test still fails: <UnitTestResult executionId="ab0d5538-a214-4032-81c7-e17465d0d52a" testId="9792fd96-52fa-4023-bc01-3316d83a33ea" testName="Microsoft.DotNet.CoreSetup.Test.HostActivation.PortableAppActivation.Muxer_Activation_With_Templated_AdditionalProbingPath_Succeeds" computerName="DAGOOD-2" duration="00:00:01.1810000" startTime="2019-04-16T17:17:25.6977765-05:00" endTime="2019-04-16T17:17:25.6977823-05:00" testType="13cdc9d9-ddb5-4fa4-a97d-d965ccfc6d4b" outcome="Failed" testListId="8c84fa94-04c1-424b-9868-57a2d4851a1d" relativeResultsDirectory="ab0d5538-a214-4032-81c7-e17465d0d52a">
<Output>
<ErrorInfo>
<Message>Microsoft.DotNet.Cli.Build.Framework.BuildFailureException : Command failed with exit code 1: C:\git\core-setup\Tools/dotnetcli/dotnet.exe store --runtime win-x64 --framework netcoreapp3.0 --manifest C:\git\core-setup\src\test\Assets\TestProjects\PortableApp\PortableApp.csproj -o C:\git\core-setup\bin\tests\win-x64.Release\4\PortableApp\store /p:MNAVersion=3.0.0-preview5-27616-0 /p:NETCoreAppFramework=netcoreapp3.0 /p:OutputType=Library
Standard Output:
Microsoft (R) Build Engine version 15.8.166+gd4e8d81a88 for .NET Core
Copyright (C) Microsoft Corporation. All rights reserved.

Restoring packages for C:\git\core-setup\src\test\Assets\TestProjects\PortableApp\PortableApp.csproj...
Generating MSBuild file C:\Users\dagood\AppData\Local\Temp\il2uju1l.qut\Optimize\PortableApp.csproj.nuget.g.props.
Generating MSBuild file C:\Users\dagood\AppData\Local\Temp\il2uju1l.qut\Optimize\PortableApp.csproj.nuget.g.targets.
Restore completed in 118.28 ms for C:\git\core-setup\src\test\Assets\TestProjects\PortableApp\PortableApp.csproj.
C:\git\core-setup\Tools\dotnetcli\sdk\2.1.401\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.CrossGen.targets(48,5): error NETSDK1016: Unable to find resolved path for 'coreclr'. [C:\git\core-setup\src\test\Assets\TestProjects\PortableApp\PortableApp.csproj]

</Message>
<StackTrace> at Microsoft.DotNet.Cli.Build.Framework.CommandResult.EnsureSuccessful(Boolean suppressOutput) in C:\git\core-setup\src\test\TestUtils\CommandResult.cs:line 47
at Microsoft.DotNet.CoreSetup.Test.TestProjectFixture.StoreProject(DotNetCli dotnet, String runtime, String framework, String manifest, String outputDirectory) in C:\git\core-setup\src\test\TestUtils\TestProjectFixture.cs:line 228
at Microsoft.DotNet.CoreSetup.Test.HostActivation.PortableAppActivation.CreateAStore(TestProjectFixture testProjectFixture) in C:\git\core-setup\src\test\HostActivationTests\PortableAppActivation.cs:line 433
at Microsoft.DotNet.CoreSetup.Test.HostActivation.PortableAppActivation.Muxer_Activation_With_Templated_AdditionalProbingPath_Succeeds() in C:\git\core-setup\src\test\HostActivationTests\PortableAppActivation.cs:line 131</StackTrace>
</ErrorInfo>
</Output>
</UnitTestResult>
/cc @vitek-karas @swaroop-sridhar (in case you have suggestions on how you expect the tests to evolve in 3.0) |
There are 2 sets of assemblies we use to run the tests.
I don't see us changing this structure for 3.0 in any interesting way. We are trying to limit the number of tests which will actually end up truly running the managed code using the produced NETCoreApp, but we can't completely remove those (they are very valuable as end to end tests). |
Thanks for the input. The test applications are what's broken, so I'll just do whatever looks the most straightforward to get them running again. |
To work around not getting some NuGet features that we won't get in time for 3.0, we need to provide a mostly empty Microsoft.NETCore.App package for the SDK to implement some fixes.
Proposal (thanks for this @dsplaisted!):
Microsoft.NETCore.App
package to something likeMicrosoft.NETCore.App.Internal
orMicrosoft.NETCore.App.Insertion
Microsoft.NETCore.App
package which has no assets, and only has a dependency onMicrosoft.NETCore.Platforms
Issues this will help with:
Microsoft.NETCore.App
is in the dependency graph: Restore fails if netstandard1.x package reference is present sdk#3044Microsoft.NETCore.Platforms
Once Runtime Pack work is complete and those are used instead of
Microsoft.NETCore.App
, we can stop producingMicrosoft.NETCore.App.Internal
./cc @nguerrera
The text was updated successfully, but these errors were encountered: