react-native-firebase icon indicating copy to clipboard operation
react-native-firebase copied to clipboard

Can't run on android

Open Patatruffe34 opened this issue 9 years ago • 5 comments

Hi guys

The lib is working like a charm on iOS (and thanks a lot for such an amazing job) ; However, I can't get it working on Android.

capture d ecran 2017-04-11 a 11 24 10

Here are my graddle config ; app.graddle : capture d ecran 2017-04-11 a 11 21 48 capture d ecran 2017-04-11 a 11 22 03 capture d ecran 2017-04-11 a 11 22 15

Also, my android device config : capture d ecran 2017-04-11 a 11 21 27

I digged into the web and I think it might be a play-services dependices error or something like that, but I can't figure it out.

config : "firebase": "^3.7.5", "react": "^15.4.2", "react-native": "^0.42.2", "react-native-firebase": "^1.0.0-alpha12",

Any ideas ?

Thanks

Romain

Patatruffe34 avatar Apr 11 '17 09:04 Patatruffe34

See https://github.com/invertase/react-native-firebase/issues/44

Emulator doesnt have Play Services. Need to add this to a touble shooting guide!

Ehesp avatar Apr 11 '17 09:04 Ehesp

With the next release it will default to prompt to install Play Services rather than just throwing an error which will hopefully make it clearer as well

chrisbianca avatar Apr 11 '17 10:04 chrisbianca

Code 2 just means it's out of date, you can update your emulator image and make a new one to fix this, but you can also just turn off this error as its generally fine if it's slightly out of date.

Turn off error: In your initializeApp for Rnfirebase add the config option errorOnMissingPlayServices and set to false.

@chrisbianca @Ehesp might be worth making it a warning instead if its code 2 I reckon, and updating the error description to be more specific, like if you're on a geny motion device etc etc? It's just JS side that'd need changing

Salakar avatar Apr 11 '17 10:04 Salakar

Thanks guys,

Actually I was pretty sur Google services were installed and up to date. I'll have a deeper look. i'll keep you posted this afternoon.

Thanks

Patatruffe34 avatar Apr 11 '17 10:04 Patatruffe34

You were right, I updated everything and now it's working. Thanks again !

Patatruffe34 avatar Apr 11 '17 12:04 Patatruffe34