-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[🔥] Unable to reach callable cloud function - an internal error has occurred, DEADLINE_EXCEEDED, could not connect to the server #8043
Comments
I have noticed quite a few similar issues in this repo and others, listed below: #8060 There are more, I've listed the above to demonstrate this is a real issue developers are facing. I spent a number of days on this and found a reasonable workaround. Setup
I do not use EAS, all builds are local. Quick Answer
More Details
firebase.json - host bindings
NOTE: adding host binding to "ui" is optional - if you want to connect/test connection to the FB Emulator console remotely. firebase.js
NOTE: If you change USE_EMULATOR or FIREBASE_EMUALTOR_URL, please follow the instructions in Quick Answer (delete app, rebuild, restart expo clearing cache). Preferred FixI'm not sure if this is an Expo issue or Firebase issue. It's fairly easy to replicate. Create a simple app and try an auth, function, firestore or storage request. Then chanage: USE_EMULATOR or FIREBASE_EMUALTOR_IP. You should find without following the instructions I presented in Quick Answer, FB requests will fail. Hopefully someone has a better\cleaner solution, rather then having to delete the app, rebuild etc... ConclusionThis was extremely frustrating and the workaround was found through persistance and possibly some luck. I hope someone finds this post helpful. It's been hassle free development for me for the past few days :-) |
Issue
The issues are identical to those described in this closed ticket: #6263.
Randomly I was seeing the same issues on Android ( java.util.concurrent.ExecutionException ) and on iOS (.An internal error has occurred, print and inspect the error details for more information ).
After a complete reset, Android has been working fine; although I did nothing other then cleared gradle and rebuuld.
For iOS, a clean build had things running for a while. But as soon as the Android app started to work, the iOS mysteriously stopped working and hasn't worked since.
Unfortunately the message "An internal error has occurred, print and inspect the error details for more information" doesn't help with where to dive in deeper.
I was hoping replacing the firebase json files would fix things, but those files in my project are already identical to the laetst available in the Firebase console.
iOS fails calling functions live or in the production server. There is a live version of the app which continues to works fine, which only adds to the confusion.
Project Files
Javascript
Click To Expand
const addUserFunc = functions.httpsCallable('signUpUser');const response = await addUserFunc({ email, password, type: userType }); <-- code fails here
package.json
:firebase.json
for react-native-firebase v6:# N/A
iOS
Click To Expand
ios/Podfile
:AppDelegate.m
:// N/A
Android
Click To Expand
Not sure how to complete this section. The React-Native App is from an Expo Template, as it's working at the moment I've not included any further details, but if they are required, I'll be happy to provide.Have you converted to AndroidX?
android/gradle.settings
jetifier=true
for Android compatibility?jetifier
for react-native compatibility?android/build.gradle
:// N/A
android/app/build.gradle
:// N/A
android/settings.gradle
:// N/A
MainApplication.java
:// N/A
AndroidManifest.xml
:<!-- N/A -->
Environment
Click To Expand
react-native info
output:react-native-firebase
version you're using that has this issue:20.5.0
Firebase
module(s) you're using that has the issue:@react-native-firebase/functions
TypeScript
?Y
&5.3.3
Additional information that may help you:
I've lauched the project in XCode, there's no additional information in the logs.
I've tried the following:
Changing info.plist from:
To:
Edited the Product Scheme Run option and added the following argument under Arguments Passed on Launch: "-FIRDebugEnabled", no additional logs were produced.
Any suggestions please? If you need any more information from me, please let me know. Many thanks in advance.
React Native Firebase
andInvertase
on Twitter for updates on the library.The text was updated successfully, but these errors were encountered: