You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[v6] 🔥Unable to install as per quick start guide #2126
As per docs tried running: npx @react-native-community/cli@next init --template=@react-native-firebase/template@alpha <myProjectName>
Install does not complete, error: error Error: Cannot find module '/var/folders/s7/v2pwtdc96fzbv2s8j10mf3340000gn/T/rncli-init-template-k19y8J/node_modules/@react-native-firebase/template@alpha/template.config'
Think react-native-firebase is great? Please consider supporting all of the project maintainers and contributors by donating via our Open Collective where all contributors can submit expenses. [Learn More]
cc @thymikee - think this is a bug on the CLI with templates, the path to the template.config file being loaded has the NPM tag @alpha tag in the path (and also the @ from the NPM org) - should be stripped out I'm guessing. Must be a recent bug - was working a couple of days ago.
Can successfully install via the template, trying to follow docs and have installed .plist into the Xcode project but it's failing to build. Have tried auto-linking, manual linking, installing via pods, building via workspace but nothing is working. Keep getting:
'Firebase/Firebase.h' file not found
Not really the quick start I had in mind 😕and the docs feel very sporadic. I would love to contribute to the docs if only I knew the correct process to get a working build.
On that first link there are even TODO's left in the text! // TODO(salakar) React Native version requirements // TODO(salakar): Manual or Automatic linking for Android & ios
I'm sorry that you seem to have taken an exception to the way I've worded my issues, but clearly the docs are incomplete. I've followed both guides in the links above (non-pods setup) and the Xcode error I'm getting is 'Firebase/Firebase.h' file not found
Apologies! I did not see this was your own issue. We get a lot of people posting months-old followups on issues and I was scanning very quickly, let me look more closely
I see this is for the new-new stuff (CLI next etc) - I can say I tried to use all the v6 stuff and new-CLI and all that yesterday in order to make a repro case for the firebase ios sdk (which has moved to a version that react-native-firebase 5.3.x doesn't support as it is locked to 5.20.2 firebase-ios if I understand correctly), and I met with failure as well. I think it's just not baked enough yet personally (though it is labeled correctly with alphas and nexts and WIPs etc)
I got farther than the error message you indicated, but gradle wouldn't build android, with some sort of iterator error I did not dig into
I will re-try in a couple revisions but I didn't personally have time to fuzzbust, I use react-native-firebase 5.3.x exclusively for actual work
Sorry I can't help more
I would suggest indicating clearly in the title of this issue that it is a react-native-firebase 6.x issue, as 5.3.x and 6.x are very different beasts. I check the 5.3.x start periodically (as recently as a week ago even) and I know it works at least
@Salakar Yeah I can't get the other import method to work. Although to be honest, I don't really know what I'm doing in Xcode and spend the vast majority of my time copy/pasta from tutorials.
@Ehesp@Salakar works on android now! 💪 - v6 is obviously a long path, but this is huge for me (an end user) - now I can easily play to test things (like auth, which I haven't looked at yet)
@thymikee there was one interesting thing (for me). You will need a google-services.json from firebase to do this (they are free at least) but the CLI works one way and fails the other for me on linux (Ubuntu 19.04 right now but shouldn't vary vs 18)
If you do: npx @react-native-community/cli@next init --template=@react-native-firebase/template@alpha firebaseanalyzertests
it works, that part is excellent. Then I copy my Firebase credentials in: cd firebaseanalyzertests/ && cp ../firebaseanalyzertests-google-services.json android/app/google-services.json
...again, no problems. But now if I go like this: npx @react-native-community/cli@next start - it does this error when the app starts fetching the bundle:
mike@isabela:~/work/react-random/firebaseanalyzertests % npx @react-native-community/cli@next start
┌──────────────────────────────────────────────────────────────────────────────┐
│ │
│ Running Metro Bundler on port 8081. │
│ │
│ Keep Metro running while developing on any JS projects. Feel free to │
│ close this tab and run your own Metro instance if you prefer. │
│ │
│ https://github.com/facebook/react-native │
│ │
└──────────────────────────────────────────────────────────────────────────────┘
Looking for JS files in
/home/mike/work/react-random/firebaseanalyzertests
Loading dependency graph, done.
error: bundling failed: Error: Unable to resolve module `./../../../.npm/_npx/23897/lib/node_modules/@react-native-community/cli/node_modules/react-transform-hmr/lib/index.js` from `/home/mike/work/react-random/firebaseanalyzertests/App.js`: The module `./../../../.npm/_npx/23897/lib/node_modules/@react-native-community/cli/node_modules/react-transform-hmr/lib/index.js` could not be found from `/home/mike/work/react-random/firebaseanalyzertests/App.js`. Indeed, none of these files exist:
* `/home/mike/.npm/_npx/23897/lib/node_modules/@react-native-community/cli/node_modules/react-transform-hmr/lib/index.js(.native||.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx)`
* `/home/mike/.npm/_npx/23897/lib/node_modules/@react-native-community/cli/node_modules/react-transform-hmr/lib/index.js/index(.native||.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx)`
at ModuleResolver.resolveDependency (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:163:15)
at ResolutionRequest.resolveDependency (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:52:18)
at DependencyGraph.resolveDependency (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/node-haste/DependencyGraph.js:283:16)
at Object.resolve (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/lib/transformHelpers.js:262:42)
at /home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/DeltaBundler/traverseDependencies.js:399:31
at Array.map (<anonymous>)
at resolveDependencies (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/DeltaBundler/traverseDependencies.js:396:18)
at /home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/DeltaBundler/traverseDependencies.js:269:33
at Generator.next (<anonymous>)
at asyncGeneratorStep (/home/mike/.npm/_npx/27309/lib/node_modules/@react-native-community/cli/node_modules/metro/src/DeltaBundler/traverseDependencies.js:87:24)
DELTA [android, dev] ./index.js ░░░░░░░░░░░░░░░░ 0.0% (3/179), failed.
::ffff:127.0.0.1 - - [21/May/2019:16:57:18 +0000] "GET /index.delta?platform=android&dev=true&minify=false&revisionId=944783f0ba7599b3 HTTP/1.1" 500 - "-" "okhttp/3.12.1"
Maybe this is where my big reset button in react-native-clean-project would be useful? Though I tried to --reset-cache, and I tried to delete the /tmp/haste* stuff etc
When I do this: ./node_modules/.bin/react-native run-android
@mikehardy looks like npx sets up some symlinks that Metro is not able to resolve (we observe the same behavior running start command locally.) For the time being, can you add @react-native-community/cli@next as your dev dependency and run from there? That should work just fine:
@thymikee in the template here for react-native-firebase v6 it is already set, so there is no real issue here (and apart from windows, I think they'll be able to close this issue in a bit). I just wanted to make sure you were aware of the problem (sounds like you are) since all the repro commands and logs are available. Sounds like you guys are on it
@mikehardy looks like npx sets up some symlinks that Metro is not able to resolve (we observe the same behavior running start command locally.) For the time being, can you add @react-native-community/cli@next as your dev dependency and run from there? That should work just fine:
@thymikee Is the latest RN cli setting up the correct symlinks? Can we use v6 without npx?
I'm going to try adding v6 to my app this week so any info is appreciated, thanks in advance!
@bondparkerbond - in fact, npx does not work (for me on android at least) but the CLI inside module works, specifically either ./node_modules/.bin/react-native run-android or yarn react-native start will start it up for me correctly
Using npx to create the the app from the template etc is fine, it's only using npx to run react native start that's the issue, you can just run that as normal instead without npx.
Hello 👋, to help manage issues we automatically close stale issues.
This issue has been automatically marked as stale because it has not had activity for quite some time. Has this issue been fixed, or does it still require the community's attention?
This issue will be closed in 15 days if no further activity occurs.
Thank you for your contributions.
Closing this issue after a prolonged period of inactivity. If this is still present in the latest release, please feel free to create a new issue with up-to-date information.
For anyone else still having this issue: I was running into this when trying to install the template without the @alpha tag, but I made a PR to the cli that fixes it: react-native-community/cli#497
Activity
Salakar commentedon May 9, 2019
cc @thymikee - think this is a bug on the CLI with templates, the path to the template.config file being loaded has the NPM tag
@alphatag in the path (and also the@from the NPM org) - should be stripped out I'm guessing. Must be a recent bug - was working a couple of days ago.Thanks for the report @matthieunelmes 👍
NdauwaRafael commentedon May 10, 2019
I have the same issue
thymikee commentedon May 10, 2019
@Salakar we didn't have a release in ~20 days. This is a bug indeed, fixed in react-native-community/cli#364. We'll have a release shortly, right after react-native-community/cli#372 is merged (I'm waiting for someone to review it once again, help appreciated 😃)
thymikee commentedon May 10, 2019
Published
@react-native-community/cli@2.0.0-alpha.18with the fixmatthieunelmes commentedon May 10, 2019
Thanks for jumping on this, look forward to trying it out
matthieunelmes commentedon May 13, 2019
Sorry guys, no dice.
Can successfully install via the template, trying to follow docs and have installed .plist into the Xcode project but it's failing to build. Have tried auto-linking, manual linking, installing via pods, building via workspace but nothing is working. Keep getting:
'Firebase/Firebase.h' file not foundNot really the quick start I had in mind 😕and the docs feel very sporadic. I would love to contribute to the docs if only I knew the correct process to get a working build.
mikehardy commentedon May 13, 2019
@matthieunelmes please post your own issue, we have no idea what your setup is, and your error seems to be unrelated
matthieunelmes commentedon May 13, 2019
@mikehardy This is my own issue and this by following the Quick start guide:
Integrating with existing project:
https://invertase.io/oss/react-native-firebase/quick-start/existing-project
Adding Firebase to iOS: (Title on page is incorrect as it says Android)
https://invertase.io/oss/react-native-firebase/quick-start/ios-firebase-credentials
On that first link there are even TODO's left in the text!
// TODO(salakar) React Native version requirements// TODO(salakar): Manual or Automatic linking for Android & iosI'm sorry that you seem to have taken an exception to the way I've worded my issues, but clearly the docs are incomplete. I've followed both guides in the links above (non-pods setup) and the Xcode error I'm getting is
'Firebase/Firebase.h' file not foundmikehardy commentedon May 13, 2019
Apologies! I did not see this was your own issue. We get a lot of people posting months-old followups on issues and I was scanning very quickly, let me look more closely
matthieunelmes commentedon May 13, 2019
That's ok, as I say. I'm happy to help contribute to documentation once we find out what is going wrong
mikehardy commentedon May 13, 2019
I see this is for the new-new stuff (CLI next etc) - I can say I tried to use all the v6 stuff and new-CLI and all that yesterday in order to make a repro case for the firebase ios sdk (which has moved to a version that react-native-firebase 5.3.x doesn't support as it is locked to 5.20.2 firebase-ios if I understand correctly), and I met with failure as well. I think it's just not baked enough yet personally (though it is labeled correctly with alphas and nexts and WIPs etc)
I got farther than the error message you indicated, but gradle wouldn't build android, with some sort of iterator error I did not dig into
I will re-try in a couple revisions but I didn't personally have time to fuzzbust, I use react-native-firebase 5.3.x exclusively for actual work
Sorry I can't help more
I would suggest indicating clearly in the title of this issue that it is a react-native-firebase 6.x issue, as 5.3.x and 6.x are very different beasts. I check the 5.3.x start periodically (as recently as a week ago even) and I know it works at least
matthieunelmes commentedon May 13, 2019
Could you kindly link me to any V5 documentation?
EDIT
I've found it:
https://rnfirebase.io/docs/v5.x.x/getting-started
42 remaining items
matthieunelmes commentedon May 21, 2019
@Salakar Yeah I can't get the other import method to work. Although to be honest, I don't really know what I'm doing in Xcode and spend the vast majority of my time copy/pasta from tutorials.
Salakar commentedon May 21, 2019
@mikehardy oh wow - I know what this is but equally, it's not happening for me locally =/ let me dig into it a bit today, again 🙈
Salakar commentedon May 21, 2019
Thanks; I'll update the docs
Ehesp commentedon May 21, 2019
@mikehardy this should be fixed now. Out of interest are you on windows? This was an issue with the firebase.json file.
mikehardy commentedon May 21, 2019
@Ehesp @Salakar works on android now! 💪 - v6 is obviously a long path, but this is huge for me (an end user) - now I can easily play to test things (like auth, which I haven't looked at yet)
@thymikee there was one interesting thing (for me). You will need a google-services.json from firebase to do this (they are free at least) but the CLI works one way and fails the other for me on linux (Ubuntu 19.04 right now but shouldn't vary vs 18)
If you do:
npx @react-native-community/cli@next init --template=@react-native-firebase/template@alpha firebaseanalyzertestsit works, that part is excellent. Then I copy my Firebase credentials in:
cd firebaseanalyzertests/ && cp ../firebaseanalyzertests-google-services.json android/app/google-services.json...again, no problems. But now if I go like this:
npx @react-native-community/cli@next start- it does this error when the app starts fetching the bundle:Maybe this is where my big reset button in react-native-clean-project would be useful? Though I tried to --reset-cache, and I tried to delete the /tmp/haste* stuff etc
When I do this:
./node_modules/.bin/react-native run-android...everything is perfect
? 🤔
thymikee commentedon May 21, 2019
@mikehardy looks like
npxsets up some symlinks that Metro is not able to resolve (we observe the same behavior runningstartcommand locally.) For the time being, can you add@react-native-community/cli@nextas your dev dependency and run from there? That should work just fine:mikehardy commentedon May 21, 2019
@thymikee in the template here for react-native-firebase v6 it is already set, so there is no real issue here (and apart from windows, I think they'll be able to close this issue in a bit). I just wanted to make sure you were aware of the problem (sounds like you are) since all the repro commands and logs are available. Sounds like you guys are on it
bondparkerbond commentedon May 22, 2019
@thymikee Is the latest RN cli setting up the correct symlinks? Can we use v6 without npx?
I'm going to try adding v6 to my app this week so any info is appreciated, thanks in advance!
mikehardy commentedon May 22, 2019
@bondparkerbond - in fact, npx does not work (for me on android at least) but the CLI inside module works, specifically either
./node_modules/.bin/react-native run-androidoryarn react-native startwill start it up for me correctlySalakar commentedon May 23, 2019
Using npx to create the the app from the template etc is fine, it's only using npx to run
react native startthat's the issue, you can just run that as normal instead without npx.stale commentedon Jun 20, 2019
Hello 👋, to help manage issues we automatically close stale issues.
This issue has been automatically marked as stale because it has not had activity for quite some time. Has this issue been fixed, or does it still require the community's attention?
stale commentedon Jul 5, 2019
Closing this issue after a prolonged period of inactivity. If this is still present in the latest release, please feel free to create a new issue with up-to-date information.
BenLorantfy commentedon Jul 7, 2019
For anyone else still having this issue: I was running into this when trying to install the template without the
@alphatag, but I made a PR to the cli that fixes it: react-native-community/cli#497