App Store rejection - crashed on launch

#1

Hi,

I’ve built an app. Tested on android and ios simulators and it’s worked fine. Tested on devices and it’s fine. Launched on the Google Play Store with no issues. Submitted to Apple App store, tested on TestFlight and it’s fine, but on review they keep telling me it’s crashing on launch.

I’ve checked over the code, made sure all props are correct. I can’t figure out what is wrong. They’ve sent me crash reports.

My app is https://exp.host/@dancork/non-league-scores

Crash report here https://drive.google.com/file/d/0B63Y0pRBoQbIMERTV1JQYUFjeDA/view?usp=sharing

Any help would be great.

Thanks,
Dan

#2

When I open the app in the Expo client, it actually crashes the whole Expo app for me.
I’ll try to figure out why.

#3

can you share your whole project with me on github? my best guess is that when someone not you looks at the app, its triggering some kind of styling property that is invalid that is causing React Native to crash the app. i might be able to figure out what it is if i have all your code.

#4

Hi there! This crashes for me right away. Looks like your Facebook Ad view is failing with the error “no fill” and doesn’t have an error callback to report this to you. Do you have an onError callback in your ads component?

#5

Ah, thanks I will take a look at that now. Been pulling my hair out over this! @ben out of curiousity, what did you use to debug this and see that error?

#6

I built and ran the Expo Client from source code. Since it’s not reasonable for you to have to do that, I also pushed a change which will surface Facebook Ads errors more obviously in our next version, instead of just crashing.

#7

Amazing! That is a great idea.

So is it the case that it just needs an onError prop or is it a better idea to use state to not render ad component when an error is fired?

#8

i would just try adding an onError prop and then try not rendering if it looks bad, but i think its up to you.

#9

Thanks :slight_smile:

In the end I used a state param to hide the banner on error, like below…

{this.state.showAd
   <FacebookAds.BannerView
      placementId="YOUR_BANNER_PLACEMENT_ID"
      type="standard"
      onPress={() => console.log('click')}
      onError={(err) => { this.setState({ showAd: false }); console.log('error', err) }}
    />}

This seems to have worked as my app got accepted by Apple and is now live!!!

Thank you so much for all your help @ccheever and @ben

2 Likes
#10

congrats on your launch!