I’m getting the following error when trying to launch a Xamarin.iOS application on iOS 12 and below (iOS 13 and above does launch the application without issue):
Debug output:
error HE0042: Could not launch the app 'com.companyname.App1' on the device 'iOS 12.2 (16E226) - iPhone 8 Plus': The request to open "com.companyname.App1" failed.
Simulator System.Log
com.apple.CoreSimulator.SimDevice.B80099F4-F084-4872-A08A-87BD762045BF[2469] (UIKitApplication:com.companyname.App1[0x3536][2491][3415]): removing service since it exited with consistent failure - OS_REASON_EXEC
This error even occurs on a newly generated application using VS for Mac or Rider.
Things I tried without any result:
-
Erase All Content and Settings in the simulator (https://forums.xamarin.com/discussion/65978/debugger-wont-start-app-on-ios-device)
-
Reinstalling CoreSimulator (Xamarin.iOS: Cannot run after Visual Studio 2019 Update)
-
Clean Project, delete bin & obj folders & rebuild project
Is there anyone that experienced the same issue and how did you fix it?
Thanks!
2
Answers
In the iOS project properties in Visual Studio under ‘iOS Build’ I checked ‘Use the concurrent garbage collector’.
That handled it in my case.
This was happening to me as well in my debug iphone simulator builds. The fix, for me, was to set the project’s iOS Bundle Signing -> Custom Entitlements to Entitlements.plist. This will force the application to be signed.