Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Apps manually installed in simulator crashes upon load

I'm installing MyApp on the iOS simulator (Xcode 7, iOS 9) using xcrun simctl install booted MyPath/MyApp.app.

This works as expected and the app is installed on the simulator.

However, launching the app either manually or using xcrun simctl launch booted com.company.MyApp fails. Giving back the error:

An error was encountered processing the command (domain=FBSOpenApplicationErrorDomain, code=1): The operation couldn’t be completed. (FBSOpenApplicationErrorDomain error 1.)

The app is exported from Xcode (note that running the app from Xcode or re-building the app from its source code is not a liable solution).

It's not app specific, as any app install in this manner crashes with the same error.

The system log reports the same error, but with some additional information.

com.apple.CoreSimulator.SimDevice.CA35ED48-DDAA-4CF0-8C69-C206CC55A6EB.launchd_sim[4200] (UIKitApplication:com.company.MyApp[0xe9ec][4281]): Program specified by service does not contain one of the requested architectures: R

SpringBoard[4217]: Unable to get pid for 'UIKitApplication:com.company.MyApp[0xe9ec]': No such process (err 3)

SpringBoard[4217]: Bootstrapping failed for

SpringBoard[4217]: Application 'UIKitApplication:com.company.MyApp[0xe9ec]' exited voluntarily.

SpringBoard[4217]: CGContextSaveGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

SpringBoard[4217]: CGContextTranslateCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

SpringBoard[4217]: CGContextRestoreGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

SpringBoard[4217]: CGContextSaveGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

SpringBoard[4217]: CGContextTranslateCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

SpringBoard[4217]: CGContextRestoreGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.

com.apple.CoreSimulator.SimDevice.CA35ED48-DDAA-4CF0-8C69-C206CC55A6EB.launchd_sim[4200] (UIKitApplication:com.company.MyApp[0xc82f][4282]): Program specified by service does not contain one of the requested architectures: R

SpringBoard[4217]: Unable to get pid for 'UIKitApplication:com.company.MyApp[0xc82f]': No such process (err 3)

SpringBoard[4217]: Bootstrapping failed for

SpringBoard[4217]: Application 'UIKitApplication:com.company.MyApp[0xc82f]' exited voluntarily.

The architectures error varies the variable. R, f, etc.

What's the causing this issue? How may I resolve it?

like image 216
Aleksander Azizi Avatar asked Oct 02 '15 11:10

Aleksander Azizi


People also ask

Why is my app closing as soon as I open it?

Apps on Android can crash because of low storage space, too many apps running simultaneously, a weak internet connection, or not having the proper app updates installed.

How do you fix an app that keeps crashing?

To fix Android apps that keep crashing: To do this, go to Settings and open Apps. Under Your apps, you'll see a list of the apps currently installed on your device. From the list, tap the app that keeps crashing and tap Force stop in the bottom right corner. Then try opening the app again.

Why does my game app keep closing?

If your Android apps keep crashing or freezing it's usually because you're low on space or running too many apps at once. Other reasons for crashing apps include a spotty Wi-Fi connection or an old version of the app that hasn't been updated.

How do you download apps on simulator?

Install Apps on SimulatorsGo to Apps > Install Application. Find and open the app you want to install from your Mac. The app appears in the list of installed apps on the right side of the iOS Gateway window.


1 Answers

I had the same problem, but using Xamarin. In Visual Studio I solved it by going to the iOS project properties and under "iOS Build" I changed the "Supported architectures" from "i386" to "i386 + x86_64".

Hopefully you can adapt that to XCode.

like image 53
Decept Avatar answered Oct 03 '22 11:10

Decept