maui: Assembly 'Microsoft.Maui' Version=1.0.0.0 uses 'Microsoft.iOS, Version=16.0.0.0 which has a higher version than referenced assembly 'Microsoft.iOS' 15.4.300.0 -- FAILED.
Description
This is a recurrence of issue #8858 that was determined not to be a bug, but I am having difficulty finding a way to work around it with the latest visual studio releases.
With the latest preview of visual studio, it has the following workloads:
Installed Workload Ids Manifest Version Installation Source
maui-windows 6.0.541/6.0.400 VS 17.3.32929.385 maui-maccatalyst 6.0.541/6.0.400 VS 17.3.32929.385 maccatalyst 15.4.454/6.0.400 VS 17.3.32929.385 maui-ios 6.0.541/6.0.400 VS 17.3.32929.385 ios 15.4.454/6.0.400 VS 17.3.32929.385 maui-android 6.0.541/6.0.400 VS 17.3.32929.385 android 32.0.476/6.0.400 VS 17.3.32929.385
The upgrade at least got rid of a version complaint blocking pairing about emscript, so I was quite hopeful. I uninstalled xcode 14 on my mac and went back to 13.3 as that is supposed to be supported next week. Also, with the preview version I now see iOS simulators again with 13.3 installed.
Building seems to go well, but I get the dreaded (by me in recent weeks at least) message above which does not provide much actionable information. I already uninstalled all of visual studio and reinstalled and behavior remains consistent.
maui-check shows the following in red:
.NET SDK - Workloads (6.0.301) Checkup… x android (Microsoft.NET.Sdk.Android.Manifest-6.0.300 : 32.0.440) not installed. x ios (Microsoft.NET.Sdk.iOS.Manifest-6.0.300 : 16.0.517) not installed. x maccatalyst (Microsoft.NET.Sdk.MacCatalyst.Manifest-6.0.400 : 15.4.465) not installed. x tvos (Microsoft.NET.Sdk.tvOS.Manifest-6.0.400 : 16.0.517) not installed. x macos (Microsoft.NET.Sdk.macOS.Manifest-6.0.400 : 12.3.465) not installed. x maui (Microsoft.NET.Sdk.Maui.Manifest-6.0.300 : 6.0.419) not installed. ! Managing Workload installation from the CLI is NOT recommended. Instead you should install the latest Visual Studio preview to automatically get the newest release of .NET MAUI workloads installed. Are you sure you would like to continue the CLI workload installation? [y/n] (n):
But obviously, with latest preview and standard 2022 full installs, I have the latest. Giving ‘y’ a shot, just gives the following:
Failed to update the advertising manifest microsoft.net.sdk.android: microsoft.net.sdk.android.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)“…
Failed to update the advertising manifest microsoft.net.sdk.ios: microsoft.net.sdk.ios.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)”…
Failed to update the advertising manifest microsoft.net.sdk.maccatalyst: microsoft.net.sdk.maccatalyst.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)“…
Failed to update the advertising manifest microsoft.net.sdk.macos: microsoft.net.sdk.macos.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)”…
Failed to update the advertising manifest microsoft.net.sdk.maui: microsoft.net.sdk.maui.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)“…
Failed to update the advertising manifest microsoft.net.sdk.tvos: microsoft.net.sdk.tvos.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)”…
Failed to update the advertising manifest microsoft.net.workload.emscripten: microsoft.net.workload.emscripten.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)“…
Failed to update the advertising manifest microsoft.net.workload.mono.toolchain: microsoft.net.workload.mono.toolchain.manifest-6.0.300 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)”…
Downloading microsoft.net.sdk.android.manifest-6.0.300.msi.x64 (32.0.440)
Workload installation failed. Rolling back installed packs…
Downloading microsoft.net.sdk.android.manifest-6.0.300.msi.x64 (32.0.301)
Installation rollback failed: One or more errors occurred. (microsoft.net.sdk.android.manifest-6.0.300.msi.x64::32.0.301 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)“.)
Workload installation failed: One or more errors occurred. (microsoft.net.sdk.android.manifest-6.0.300.msi.x64::32.0.440 is not found in NuGet feeds C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc$(PACKAGE_SOURCE_NUGET_ORG)”.)
Fix failed - Workload Install failed: dotnet workload install --from-rollback-file "C:\Users\User\AppData\Local\Temp\maui-check-2626c1fc\workload.json" android ios maccatalyst tvos macos maui --source "$(PACKAGE_SOURCE_NUGET_ORG)"
which rolls everything back so no changes are made.
Is this something where you can point me to something to change or is it likely I just need to wait for next week’s build?
Thanks! Victor
Steps to Reproduce
MAUI project targeting net6.0-ios.
Visual Studio 2022 preview 3.0
Pair to mac succeeds.
Build almost succeeds but at the very end spits out:
CSC : error CS1705: Assembly ‘Microsoft.Maui’ with identity ‘Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null’ uses ‘Microsoft.iOS, Version=16.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065’ which has a higher version than referenced assembly ‘Microsoft.iOS’ with identity ‘Microsoft.iOS, Version=15.4.300.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065’
The app works fine on Android, but to do so, I have to remove iOS targeting for build to succeed.
my global.json: { “sdk”: { “version”: “6.0.401” } }
Link to public reproduction project repository
n/a
Version with bug
6.0 Release Candidate 2 or older
Last version that worked well
6.0.400
Affected platforms
iOS
Affected platform versions
iOS
Did you find any workaround?
I was able to build and deploy a single time immediately after rebuilding mac / windows machines entirely. I think 2022 worked, but once I used preview it changed things up, but I was previously getting a version mismatch on Emscript until today’s patch after which I’m getting the maui assembly version info message
Relevant log output
Build started...
1>------ Build started: Project: YourCompany, Configuration: Debug Any CPU ------
1>Executing SayHello Task to establish a connection to a Remote Server.
1> Properties:
1> SessionId=83d9ddd4ba76b43fd4e51a150853625f3e4e2a02b9c8e8c1252149b606d298e2,
1> Addresss=10.67.42.107,
1> SshPort=22,
1> TcpPort=50660,
1> User=VWilcox,
1> AppName=YourCompany,
1> VisualStudioProcessId=44476,
1> ContinueOnDisconnected=False
1>C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\YourCompanyState.Tasks.cs(21,49,21,73): warning CS0067: The event 'YourCompanyState.workflowTaskValueUpdated' is never used
1>C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\YourCompanyState.Tasks.cs(21,49,21,73): warning CS0067: The event 'YourCompanyState.workflowTaskValueUpdated' is never used
1>Detected signing identity:
1> Bundle Id: com.yourCompanyinc.yourCompany
1> App Id: com.yourCompanyinc.yourCompany
1>C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\YourCompanyState.Tasks.cs(21,49,21,73): warning CS0067: The event 'YourCompanyState.workflowTaskValueUpdated' is never used
1>CSC : error CS1705: Assembly 'Microsoft.Maui' with identity 'Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' uses 'Microsoft.iOS, Version=16.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065' which has a higher version than referenced assembly 'Microsoft.iOS' with identity 'Microsoft.iOS, Version=15.4.300.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065'
1>Done building project "YourCompany.csproj" -- FAILED.
1>YourCompany -> C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\bin\Debug\net6.0-maccatalyst\maccatalyst-x64\YourCompany.dll
1>YourCompany -> C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\bin\Debug\net6.0-windows10.0.19041.0\win10-x64\YourCompany.dll
Error List:
Severity Code Description Project File Line Suppression State
Error CS1705 Assembly 'Microsoft.Maui' with identity 'Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' uses 'Microsoft.iOS, Version=16.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065' which has a higher version than referenced assembly 'Microsoft.iOS' with identity 'Microsoft.iOS, Version=15.4.300.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065' YourCompany (net6.0-ios) C:\src\YourCompanyPro\Mobile\MAUI\YourCompany\CSC 1 Active
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 2
- Comments: 38
@neoayi I’m glad your approach worked for you, but I’m sure this is not acceptable “solution” for most of developers with their development environments contains third party extensions that had to be re-installed and re-configured. Microsoft needs to fix the issue that they created with this VS update. Unfortunately, lately I cannot trust VS “stable” updates, after each update I only hope that I will be able to continue to work on my projects, especially when you have a deadline pressure hope transforms to fear.
P.S. This issue not just for a “preview” installation of VS, example the same problem with latest VS 2022 ver. 17.3.6 which is supposed to be a “stable” current version.
This issue is being closed due to inactivity. If this issue is still affecting you, please follow the steps above to use the VS Feedback Tool to report the issue.
@VWilcox2000 I think (conspiracy theory on my end 😃 ), that iOS MAUI team spend majority of their time on Mac not on PC. This is why their workload deployments works for them (High Five everyone, another successful release!), but no one is spending time to test it on PC. This is my evidence:
Following is output from my console on Mac:
$ dotnet build MSBuild version 17.3.2+561848881 for .NET Determining projects to restore… All projects are up-to-date for restore. Detected signing identity:
1 -> /Users/m*****/Documents/Temp/1/bin/Debug/net6.0-ios/iossimulator-x64/1.dll Optimizing assemblies for size, which may change the behavior of the app. Be sure to test after publishing. See: https://aka.ms/dotnet-illink
Build succeeded. 0 Warning(s) 0 Error(s)
Time Elapsed 00:00:03.16
maui-check output looks very cheerful as well:
.NET SDK - Workloads (6.0.301) Checkup… ✔ android (Microsoft.NET.Sdk.Android.Manifest-6.0.300 : 32.0.440) installed. ✔ ios (Microsoft.NET.Sdk.iOS.Manifest-6.0.300 : 16.0.517) installed. ✔ maccatalyst (Microsoft.NET.Sdk.MacCatalyst.Manifest-6.0.400 : 15.4.465) installed. ✔ tvos (Microsoft.NET.Sdk.tvOS.Manifest-6.0.400 : 16.0.517) installed. ✔ macos (Microsoft.NET.Sdk.macOS.Manifest-6.0.400 : 12.3.465) installed. ✔ maui (Microsoft.NET.Sdk.Maui.Manifest-6.0.300 : 6.0.419) installed.
Connect the dots… ¯_(ツ)_/¯
Same issue!
for me, uninstall all dotnet sdk, reinstall SDK 6.0, and VS 2022 17.3, it’s OK.
@janduldhardt @jk-ltc this is what I did to make it work:
I hope this will help you. I cannot say for sure that this are exactly 5 steps that make my development environment operational, because I was doing other thing previous to those steps (like run repair on Visual Studio and .Net SDK). But after this “5 steps program” I can build and actually run my MAUI app on iOS simulator (xCode 14).
This saved me. https://github.com/dotnet/sdk/issues/27587#issuecomment-1279760064
Same here. Very annoying. There should be less bugs with every release… not more 😦
@VWilcox2000 Thank you for the work around. RESPECT !
@belmonmi
I at least have had luck working on Android by editing the project and removing iOS from the target frameworks:
You can achieve the same turning off the targets in the project, of course.
@foximoxi I think you nailed it. Sometimes mistakes happens and it is OK, sometime third-party products that you relay on change their interfaces/protocols (xCode 13 vs. xCode 14) and this is understandable as well. But when you have 2 or 3 release in the row that cripple or completely stop development - this is a sign. Clearly .NET MAUI iOS team need to take a good look at their development process and figure out why this keep happening. Before VS ver. 17.3.6 release, iOS was broken, but at least I was able to build and debug on Android and moving on, expecting that by the time I’m ready to release MS will figure out the iOS issues. But now, I cannot even build. 😦
Updated VS2022 earlier today and it immediately broke my ios build with the same error as above. Tried creating a new hello world MAUI app from scratch in VS2022 and this is seeing the same issue.