React Native iOS Build in Release configuration freezes on Launch Screen - ios

I have an application built using React Native 0.58.6. The iOS build works fine in Debug configuration, but not when built in Release configuration. I can reproduce this on our build server and also locally using react-native run-ios --configuration Release.
This app worked previously in Release configuration before upgrading RN version. Does anyone have any tips for how to find out more information about what may be going on or how to fix this? The app does not crash or show any errors, just stays stuck on the LaunchScreen.xib.
Edit 1
The build works and progresses past the loading screen in the following configurations: Android/Debug, Android/Release, iOS/Debug. It is only the iOS/Release build that is failing. Also, we've tried various xCode versions including 10.1, 10.2, and 10.2.1. Still getting the same result with each version of xCode.
Any tips on how to debug something like this? With no crash, we aren't getting crash reports, and since it's a release build there is no debugging capability or console logging.

If you are using react-native-splash-screen you maybe forgot to hide it.
import SplashScreen from 'react-native-splash-screen'
...
SplashScreen.hide();

Related

iOS - Flutter audioplayers plugin error on xcode (Not found) on Release mode

When I test it on iOS Simulator on debug mode, it works fine but when I try to run on release mode on XCode it give me the following error:
Module 'audioplayers' not found
I use audioplayers 0.18.3
I remove the Pods and reinstall but not effect in release mode. Don't have problem with archive the app so is very strange. Need take screenshots of the app (in release mode, without debug banner) and I don't have a physical iOS device, so the only solution for me is take screenshots from iOS Simulator in release mode, but have this problem
Error Screenshot
PD: I'm running the .xcworkspace file.
PD2: I'm running flutter build ios and open xcode (.xcworkspace file), and run 'clean build folder' but the error persist
PD3: Sorry my bad english
Thanks since now!

Xcode debug build vs release build

I am currently building a react native app using expo.
However, I needed to use cocoapods, which is why I am now using Xcode.
Since I have switched to Xcode, there has been a difference between my local debugging builds (that I run to a USB connected iPhone) vs the builds that get pushed to TestFlight.
After doing some digging I have found that it may be due to the debug vs release schemes in Xcode.
From what I've see it seems that the difference should really just be in performance, file sizes, and some other aspects, but not what the app actually does and displays like in my case.
To test, I made a change on my app's homepage to simply have the text, UPDATED.
As expected, when ran with the debug scheme, the UPDATED text shows up, but when ran with the release scheme, it does not.
How do I get these to sync up and have the release build recognize the changes I make as I am certain I do not want to push a debug build to the app store?
Things I have tried:
Removing/cleaning Build folder and rebuilding
Updating Xcode
Running on another device
Building/running with expo (this did something, but it just causes the app to crash, assuming it is because of the cocoapods)
Versions:
react-native: 0.61.5
Xcode: 11.4.1
macOS: 10.15.3
Thank you
I have fixed the issue.
I found that by running expo publish in the terminal and then building with the release archive scheme in Xcode, it notices the changes.
Now why that is required (maybe it isn't), I am unsure of.
If anyone has an any additional insight, it would be greatly appreciated.
EDIT: So it looks like when I run expo publish it updates the app.bundle and app.manifest. This must be what the release scheme looks at when building.

React Native: What is the difference between running app with Xcode vs `react-native run-ios`?

I know that clicking run in Xcode builds and runs the project. But running react-native run-ios also builds and runs it. What's the difference other than that Xcode has more specific error messages?
react-native run-ios
is nothing but a CLI to help get you started with much more easier and faster ways to boot up the app. But for this command to execute you need to have Xcode installed and the build settings should be set to legacy so that it can be build and run properly.
The thing is suppose you want to run an app, opening the xcworkspace in your Xcode and then launching xcode , then indexing etc takes a lot of time.
SO thats where the CLI ,
react-native run-ios
helps to build faster. but at the end its the same build. This article will explain beautifully how it works. rn-ios
Hope it helps. feel free for doubts

React-Native app can build for debugging but not for archiving

I'm trying to archive my iOS app which works fine when I build for debugging via xcode but when I try to archive the app I get the following errors which I'm not sure what's causing it
I think the real reason for failure would be a little above in the listing, which cannot be seen here.
I had similar kind of issue when updated react native to version 0.54.2 the iOS archive stopped working.
My error message was something like:
A problem occurred while trying to fetch the minifier. Path: "metro-minify-uglify" Cannot find module 'uglify-es'
And the problem was that my react native project only had uglify-js in node-modules (I quess that the new react native needed the uglify-es). So I installed that with:
npm install uglify-es --save
And after that I did (not sure if these are needed) xCode->clean project, shutdown xCode, delete Library->Developer->Xcode->DerivedData, restart Xcode and archive started working again.

UI automation error using iOS 5.1 target

I use Instruments 4.3 with UI automation tool for sometime successfully.
Recently I upgraded my target iPhone4 to iOS 5.1 and UI automation is now giving following error :"An error occurred while trying to run the script" for the moment a script is started, no further info than that.
Even when Instruments is running independently from Xcode the problem is still their, also when "run on record" is ticked but no script is selected.
I even reinstalled Xcode 4.3.1 but without success.
Runs fine on simulator and previous iOS version though.
If anyone encountered this issue and has a solution, please reply.
Thanks,

Resources