MAUI, iOS simulator. "ResolveNativeReferences" exception.
See original GitHub issuePackage
Sentry.Maui
.NET Version
6.0.0 (or 7.0.0)
OS
iOS
SDK Version
3.23.1-preview.3
Steps to Reproduce
- Create a new MAUI project.
- Open .csproj-file.
- Add a reference
<PackageReference Include="Sentry.Maui" Version="3.23.1-preview.3" />
- Rebuild this project and try to run it on the iOS simulator.
Expected Result
Project should be successfully started.
Actual Result
This exception is thrown at compile time. It’s 100% about Sentry, cause with other packages I don’t get any errors.
Severity Code Description Project File Line Suppression State
Error MSB4018 The "ResolveNativeReferences" task failed unexpectedly.
System.AggregateException: One or more errors occurred. ---> System.ComponentModel.Win32Exception: The system cannot find the file specified
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at Xamarin.Utils.Execution.<>c__DisplayClass24_1.<RunAsync>b__0() in /Users/builder/azdo/_work/1/s/xamarin-macios/tools/common/Execution.cs:line 103
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Xamarin.MacDev.Tasks.XamarinTask.<ExecuteAsync>d__24.MoveNext() in /Users/builder/azdo/_work/1/s/xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs:line 120
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at System.Threading.Tasks.Task.Wait()
at Xamarin.MacDev.Tasks.ResolveNativeReferencesBase.ProcessSidecar(ITaskItem r, String resources, List`1 native_frameworks) in /Users/builder/azdo/_work/1/s/xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Tasks/ResolveNativeReferencesBase.cs:line 134
at Xamarin.MacDev.Tasks.ResolveNativeReferencesBase.Execute() in /Users/builder/azdo/_work/1/s/xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Tasks/ResolveNativeReferencesBase.cs:line 105
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext()
---> (Inner Exception #0) System.ComponentModel.Win32Exception (0x80004005): The system cannot find the file specified
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at Xamarin.Utils.Execution.<>c__DisplayClass24_1.<RunAsync>b__0() in /Users/builder/azdo/_work/1/s/xamarin-macios/tools/common/Execution.cs:line 103
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Xamarin.MacDev.Tasks.XamarinTask.<ExecuteAsync>d__24.MoveNext() in /Users/builder/azdo/_work/1/s/xamarin-macios/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs:line 120<---
MauiApp2 C:\Program Files\dotnet\packs\Microsoft.iOS.Sdk\16.0.527\tools\msbuild\iOS\Xamarin.Shared.targets 137
Issue Analytics
- State:
- Created 10 months ago
- Reactions:1
- Comments:11 (8 by maintainers)
Top Results From Across the Web
MAUI App launches fine in iOS Simulator, refuses to build ...
When I start building a default MAUI project for a physical iOS device on Visual Studio for Mac Preview 17.3 (build 191) on...
Read more >Deploying .NET MAUI to IOS Simulator Error
I am having an issue deploying to any iOS simulator using .NET Maui. I receive the following error Failed to install the app...
Read more >Error adding record: MissingEntity - Microsoft Q&A
When running the [await SecureStorage. SetAsync] command in the MAUI IOS simulator, an error is reported: Error adding record: MissingEntity.
Read more >MAUI with Blazor iOS, how to debug errors?
Just go to Safari > Development > Look for the simulator > it should probably say something like "localhost" and give it a...
Read more >Troubleshooting iOS Simulator Crashes when Using ...
When I used the RadCartesianChart and RadPieChart in MAUI with the sample code from https://docs.telerik.com/devtools/maui/controls/chart/types/ ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@bozau - Yes - Microsoft is working on this with xamarin/xamarin-macios#16001.
Also, I just developed a workaround we can use for Sentry. It’s not a general-purpose workaround for the whole issue, but it side-steps us running into it by preventing the resources zip file from being created to begin with. It will be released shortly. Thanks.
Not sure that we’re going to be able to workaround this one. Until Microsoft has a fix, I suggest one of the following:
If a workaround becomes apparent, we’ll add it. Thanks.