Skip to content
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

RC1 File/New MAUI Blazor Hybrid gets several MA002 warnings about UseMaui and SkipValidateMauiImplicitPackageReferences #17561

Closed
Eilon opened this issue Sep 21, 2023 · 2 comments · Fixed by #17579
Assignees
Labels
area-setup Installation, setup, requirements, maui-check, workloads, platform support fixed-in-8.0.0-rc.2.9373 Look for this fix in 8.0.0-rc.2.9373! t/bug Something isn't working
Milestone

Comments

@Eilon
Copy link
Member

Eilon commented Sep 21, 2023

Repro:

  1. Install VS 2023 Preview w/ .NET 8 RC1
  2. Create new MAUI Blazor Hybrid project
  3. Build it

Expected: No warnings

Actual: Got these warnings:

1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(74,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.Maui.Controls" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(79,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(74,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.Maui.Controls" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(79,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(74,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.Maui.Controls" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(79,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(74,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.Maui.Controls" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.
1>C:\Program Files\dotnet\packs\Microsoft.Maui.Sdk\8.0.0-rc.1.9171\Sdk\BundledVersions.targets(79,5): warning MA002: Starting with .NET 8, setting  <UseMaui>true</UseMaui>  does not automatically include NuGet package references in your project.  Update your project by including this item:  <PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="8.0.0-rc.1.9171" />.  You can skip this warning by setting  <SkipValidateMauiImplicitPackageReferences>true</SkipValidateMauiImplicitPackageReferences>  in your project file.

This does not happen with a non-Hybrid MAUI project.

See this MSBuild binlog for more details: MauiApp1_Debug_AnyCPU_Build_2023-09-21T16_11_34.6445119-07_00.binlog.zip

@Eilon Eilon added t/bug Something isn't working area-setup Installation, setup, requirements, maui-check, workloads, platform support i/regression This issue described a confirmed regression on a currently supported version labels Sep 21, 2023
@Eilon
Copy link
Member Author

Eilon commented Sep 21, 2023

I don't see any obvious reason why this would be different between the regular MAUI template and Blazor MAUI template... they seem quite similar in this regard.

@Eilon
Copy link
Member Author

Eilon commented Sep 22, 2023

cc @mattleibow because this was introduced in #14770 a while ago. I think this has been happening since at least .NET 8 Preview 7.

@PureWeen PureWeen added this to the .NET 8 GA milestone Sep 22, 2023
@mattleibow mattleibow removed the i/regression This issue described a confirmed regression on a currently supported version label Sep 22, 2023
@samhouts samhouts added the fixed-in-8.0.0-rc.2.9373 Look for this fix in 8.0.0-rc.2.9373! label Oct 10, 2023
@dotnet dotnet locked as resolved and limited conversation to collaborators Nov 9, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-setup Installation, setup, requirements, maui-check, workloads, platform support fixed-in-8.0.0-rc.2.9373 Look for this fix in 8.0.0-rc.2.9373! t/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants