question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Bug] MAUI project fails to build with .NET 6 SDK daily

See original GitHub issue
  1. Install https://aka.ms/dotnet/6.0/daily/dotnet-sdk-osx-x64.pkg
  2. Create test.csproj
<Project Sdk="Microsoft.NET.Sdk">
    <PropertyGroup>
        <TargetFramework>net6.0-android</TargetFramework>
        <OutputType>Exe</OutputType>
        <UseMaui>true</UseMaui>
    </PropertyGroup>
</Project>
  1. Run dotnet build test.csproj
~/Projects/my: dotnet build test.csproj
Microsoft (R) Build Engine version 17.0.0-preview-21323-02+67ba2dfd7 for .NET
Copyright (C) Microsoft Corporation. All rights reserved.
 
  Determining projects to restore...
/usr/local/share/dotnet/sdk/6.0.100-preview.7.21326.2/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.ImportWorkloads.targets(33,5): error NETSDK1147: To build this project, the following workloads must be installed: microsoft-android-sdk-full maui-core microsoft-net-runtime-mono-tooling [/Users/xxxx/Projects/my/test.csproj]
/usr/local/share/dotnet/sdk/6.0.100-preview.7.21326.2/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.ImportWorkloads.targets(33,5): error NETSDK1147: To install these workloads, run the following command: dotnet workload install microsoft-android-sdk-full maui-core microsoft-net-runtime-mono-tooling [/Users/xxxx/Projects/my/test.csproj]
 
~/Projects/my: sudo dotnet workload install microsoft-android-sdk-full maui-core microsoft-net-runtime-mono-tooling
 
Failed to update the advertising manifest microsoft.net.sdk.maui: microsoft.net.sdk.maui.manifest-6.0.100 is not found in NuGet feeds https://api.nuget.org/v3/index.json"..
Skip NuGet package signing validation. NuGet signing validation is not available on Linux or macOS https://aka.ms/workloadskippackagevalidation .
Updated advertising manifest microsoft.net.sdk.maccatalyst.
Updated advertising manifest microsoft.net.sdk.macos.
Updated advertising manifest microsoft.net.sdk.android.
Updated advertising manifest microsoft.net.workload.mono.toolchain.
Updated advertising manifest microsoft.net.sdk.ios.
Updated advertising manifest microsoft.net.sdk.tvos.
Installing workload manifest microsoft.net.sdk.tvos version 14.5.100-preview.5.894.
Installing workload manifest microsoft.net.sdk.android version 30.0.100-preview.5.28.
Installing workload manifest microsoft.net.sdk.macos version 11.3.100-preview.5.894.
Installing workload manifest microsoft.net.sdk.maccatalyst version 14.5.100-preview.5.894.
Installing workload manifest microsoft.net.sdk.ios version 14.5.100-preview.5.894.
Installing pack Microsoft.Android.Sdk version 30.0.100-preview.5.28...
Writing workload pack installation record for Microsoft.Android.Sdk version 30.0.100-preview.5.28...
Installing pack Microsoft.Android.Sdk.BundleTool version 30.0.100-preview.5.28...
Writing workload pack installation record for Microsoft.Android.Sdk.BundleTool version 30.0.100-preview.5.28...
Installing pack Microsoft.Android.Ref version 30.0.100-preview.5.28...
Writing workload pack installation record for Microsoft.Android.Ref version 30.0.100-preview.5.28...
Installing pack Microsoft.Android.Templates version 30.0.100-preview.5.28...
Writing workload pack installation record for Microsoft.Android.Templates version 30.0.100-preview.5.28...
Installing pack Microsoft.AspNetCore.Components.WebView.Maui version 6.0.100-ci.main.806+sha.4f938d851-azdo.4878631...
Workload installation failed, rolling back installed packs...
Installing workload manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723.
Installation roll back failed: Failed to install manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723: The transaction has aborted..
Rolling back pack Microsoft.Android.Sdk installation...
Uninstalling workload pack Microsoft.Android.Sdk version 30.0.100-preview.5.28.
Rolling back pack Microsoft.Android.Sdk.BundleTool installation...
Uninstalling workload pack Microsoft.Android.Sdk.BundleTool version 30.0.100-preview.5.28.
Rolling back pack Microsoft.Android.Ref installation...
Uninstalling workload pack Microsoft.Android.Ref version 30.0.100-preview.5.28.
Rolling back pack Microsoft.Android.Templates installation...
Uninstalling workload pack Microsoft.Android.Templates version 30.0.100-preview.5.28.
Rolling back pack Microsoft.AspNetCore.Components.WebView.Maui installation...
Workload installation failed: microsoft.aspnetcore.components.webview.maui::6.0.100-ci.main.806 is not found in NuGet feeds https://api.nuget.org/v3/index.json".

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
lutzroedercommented, Jun 30, 2021

There are multiple issues here:

0reactions
jonathanpepperscommented, Jun 29, 2021

dotnet workload install maui will fail unless NuGet.config is added to the folder. Do we need an issue to track this?

This is expected. The packages are only pushed to NuGet.org on the release day of each preview.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshoot known issues - .NET MAUI
The solution to this issue on Windows is to uninstall the .NET MAUI workloads through the CLI, uninstall any .NET SDKs in Control...
Read more >
Opinions on .NET MAUI / what do Xamarin Devs have to say
I'm using MAUI (Hybrid) now with Blazor (server) to create cross platform apps mobile, desktop, web. (Only missing Linux hope they support it)....
Read more >
,NET MAUI GIVING ERRORS AFTER UPDATING FROM ...
I have VS 2022 17.3 installed and created a lot fo MAUi APps that are working well but when i updated VS to...
Read more >
Welcome to Hell - Windows Publishing with .NET MAUI
NET MAUI project and created a blank WinUI 3 + Windows App SDK project, since this is what MAUI for Windows is based...
Read more >
Getting started with Microsoft .NET MAUI
The Content Page you have just created only works on Xamarin.Forms projects. If you try to build the solution, it will fail: error...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found