Cristian Tr
Cristian Tr

Reputation: 716

iOS crash in testFlight on open

When running the app in test fight it crashes upon opening. The app runs well if tested directly in the simulator or on the device.

I did clean, archive and upload the app again and there was no difference. The Valid Architecture is set only to arm64

This is the error in the console

Attempt to add an app with insufficient id, info {
BKSApplicationStateAppIsFrontmost = 1;
BKSApplicationStateExtensionKey = 0;
SBApplicationStateDisplayIDKey = "org.mydomain.name";
SBApplicationStateKey = 8;
SBApplicationStateProcessIDKey = 677;
SBMostElevatedStateForProcessID = 8;
}

The app is build in react-native

React Native Environment Info:

System:
  OS: macOS High Sierra 10.13.6
  CPU: x64 Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
  Memory: 3.59 GB / 16.00 GB
  Shell: 3.2.57 - /bin/bash
Binaries:
  Node: 8.9.3 - /usr/local/bin/node
  npm: 6.1.0 - /usr/local/bin/npm
  Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
  iOS SDK:
    Platforms: iOS 12.0, macOS 10.14, tvOS 12.0, watchOS 5.0
  Android SDK:
    Build Tools: 23.0.1, 25.0.2, 25.0.3, 26.0.2, 27.0.3
    API Levels: 16, 19, 22, 23, 25, 26, 27
IDEs:
  Android Studio: 3.0 AI-171.4443003
  Xcode: 10.0/10A255 - /usr/bin/xcodebuild
npmPackages:
  react: 16.3.1 => 16.3.1
  react-native: ^0.56.0 => 0.56.0
npmGlobalPackages:
  create-react-native-app: 1.0.0
  react-native-cli: 2.0.1
  react-native-rename: 2.2.2

I have fallowed the guid for release from here https://facebook.github.io/react-native/docs/running-on-device

Any thoughts on how to fix this?

Upvotes: 6

Views: 3634

Answers (2)

Cristian Tr
Cristian Tr

Reputation: 716

It turns the crash was because of a framework '@rpath/XCTest.framework/XCTest' not being loaded, and the errors I got in the console were misleading.

I was able to see the reason after submitting the app for beta review and getting back the crashlogs.

To fix this I deleted the derivedData folder and added XCTest framework in Liked Frameworks as optional. dyld: Library not loaded: @rpath/XCTest.framework/XCTest

Upvotes: 2

shpasta
shpasta

Reputation: 1933

That could be signature or bitcode problem. First, you can regenerate your certificate and provisioning profile, create new build and upload it to TestFlight again. Then, if that didn't work, you can disable bitcode in project setting and create new build. The thing is when bitcode is ON TestFlight rebuilds apps before distribution.

Upvotes: 2

Related Questions