Running Xamarin iOS Error simctl returned exit code 4

Yohanes AI 0 Reputation points
2023-09-21T12:32:39.5166667+00:00

Hi

Three days ago, my app ran well and deployed smoothly to Emulator on my mac until today when I tried to run again, my apps cannot run with the error

Error on Visual Studio

Severity	Code	Description	Project	File	Line	Suppression State
Error		error HE0046: Failed to install the app 'com.companyname.appname' on the device 'iOS 16.4 (xxxxx) - iPhone 14 Pro': simctl returned exit code 4	

I have tried to

  1. Clear emulator data by Device -> Erase all content and Settings
  2. Check xCode -> Preferences -> Location -> Command Line Tools set to xCode 14.3.1 (14E300c)
  3. Check on the ios project properties -> iOS build -> Supported Architecture to i386 + x86_x64

When I trying to run manually the simctl here is the result

xcrun simctl install xxxx-D7E4-4571-A0B9  xxxx/Users/xxx/Library/Caches/Xamarin/mtbs/builds/app.iOS/a17f6534d68e8b9asdasdsadasdcc5319a6aed7589eecdf4b78edea37d73c0de0d639f43d/bin/iPhone/Ad-Hoc/app.app

And the result is

An error was encountered processing the command (domain=IXUserPresentableErrorDomain, code=4):
Simulator device returned an error for the requested operation.
This app needs to be updated by the developer to work on this version of iOS.
Failed to find matching arch for input file: /Users/xxx/Library/Developer/CoreSimulator/Devices/xxx-D7E4-4571-xxx-xxx/data/Library/Caches/com.apple.mobile.installd.staging/temp.iMe6mP/extracted/MaxGoiOS.app/app
Underlying error (domain=IXUserPresentableErrorDomain, code=4):
	“MyApp” Needs To Be Updated
	This app needs to be updated by the developer to work on this version of iOS.

I use Microsoft Visual Studio Enterprise 2022 (64-bit) - Current - Version 17.6.4
Mac Book Pro 2018 Ventura 13.5 Intel Core

Any idea? Thank you

Developer technologies .NET Xamarin
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Wenyan Zhang (Shanghai Wicresoft Co,.Ltd.) 36,436 Reputation points Microsoft External Staff
    2023-09-22T09:29:42.7633333+00:00

    Hello,

    on the device 'iOS 16.4 (xxxxx) - iPhone 14 Pro': simctl returned exit code 4 Check on the ios project properties -> iOS build -> Supported Architecture to i386 + x86_x64 Failed to find matching arch for input file: /Users/xxx/Library/Developer

    From the error message, there is not a matching arch, iPhone 14 pro with iOS16.4 based on Arm64, you could try to change the supported architecture.

    Best Regards,

    Wenyan Zhang


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.